function EngineInit(t) {
	G_15 = t, G_14 = [], G_0 = document.getElementById(G_15), G_2 = new GLE.Pa(45, G_0.offsetWidth / G_0.offsetHeight, 1e-6, 1e7), G_3 = new GLE.Scene;
	var e = new GLE.Geometry,
		n = new GLE.Mal({
			color: 16711680
		});
	G_35 = new GLE.Mesh(e, n), G_3.add(G_35), G_36 = new GLE.Mesh(e, n), G_35.add(G_36), G_34 = new GLE.Mesh(e, n), G_36.add(G_34), (G_30 = new GLE.Dt(16777215, 2)).position.set(100, 50, 100), G_34.add(G_30), (G_31 = new GLE.Dt(16777215, 2)).position.set(-100, -50, -100), G_34.add(G_31), G_30.target = G_34, G_31.target = G_34, G_16 = new GLE.Rr, (G_4 = new GLE.Wr({
		antialias: !0,
		precision: "highp",
		preserveDrawingBuffer: !0
	})).so(1.2 * window.devicePixelRatio), G_4.setSize(G_0.offsetWidth, G_0.offsetHeight), G_4.sr(G_29, 1), G_4.sortObjects = !0, G_4.ld = !0, G_0.appendChild(G_4.domElement), G_4.gammaInput = !0, G_4.gammaOutput = !0, (G_6 = new GLE.Wt(G_0.offsetWidth, G_0.offsetHeight)).texture.minFilter = GLE.Nr, (G_53 = new GLE.Box3).min.x = 0, G_53.min.y = 0, G_53.min.z = 0, G_53.max.x = 0, G_53.max.y = 0, G_53.max.z = 0, G_1 = new Stats, G_21 && G_0.appendChild(G_1.dom), window.addEventListener("resize", onWindowResize, !1), (G_5 = new GLE.Ts(G_2, G_4.domElement, new GLE.Vector3(0, 0, 0))).rd = 1, G_5.zd = 1, G_5.pd = 1, G_5.sg = !1, G_48 = new GLE.Ar(500), G_35.add(G_48), G_4.domElement.addEventListener("click", onClick, !0), animate(), window.Promise = window.ES6Promise
}

function onWindowResize() {
	G_2.aspect = G_0.offsetWidth / G_0.offsetHeight, G_2.ux(), G_4.setSize(G_0.offsetWidth, G_0.offsetHeight), G_6 = new GLE.Wt(G_0.offsetWidth, G_0.offsetHeight)
}

function animate() {
	var t = M_distance([G_35.position.x, G_35.position.y, G_35.position.z], [G_2.position.x, G_2.position.y, G_2.position.z]);
	t > 0 && (G_5.zd = t / G_56, G_5.pd = t / G_56), t < .3 && (G_5.zd = .3, G_5.pd = .3), requestAnimationFrame(animate), render(), G_21 && G_1.update(), G_28 && G_5.update(), OptimizeScene()
}

function render() {
	G_7 && (G_4.render(G_3, G_2), TN.update())
}

function OptimizeScene() {
	if(!(G_8.length < 1)) {
		return
	}
}

function ik0(t) {}

function ik1(t) {
	G_7 = !1, G_4.gammaInput = !1, G_4.gammaOutput = !1;
	for(c = 0; c < G_8.length; c++)
		for(r = 0; r < G_8[c].length; r++) {
			var e = G_3.ge(G_8[c][r].model);
			if(e.material.wireframe) e.visible = !1;
			else {
				e.material = new GLE.Mal;
				G_8[c][r].color;
				e.material.color.setHex(G_8[c][r].color)
			}
		}
	G_4.sr(0, 1), G_4.render(G_3, G_2, G_6);
	var n = new Uint8Array(4);
	G_4.rls(G_6, t.pageX - G_4.domElement.getBoundingClientRect().left, G_6.height - (t.pageY - G_4.domElement.getBoundingClientRect().top), 1, 1, n);
	var i = n[0] << 16 | n[1] << 8 | n[2];
	if(0 == i) {
		G_7 = !0, G_4.sr(G_29, 1);
		for(c = 0; c < G_8.length; c++)
			for(r = 0; r < G_8[c].length; r++)(a = G_3.ge(G_8[c][r].model)).material.wireframe ? a.visible = !0 : (a.material = G_11[c], a.material.color.setHex("0xffffff"));
		return ShowSpace(!1), void OnClickBlank()
	}
	G_4.sr(G_29, 1);
	for(c = 0; c < G_8.length; c++)
		for(var r = 0; r < G_8[c].length; r++) {
			var a = G_3.ge(G_8[c][r].model);
			a.material.wireframe ? a.visible = !0 : (a.material = G_11[c], a.material.color.setHex("0xffffff"))
		}
	if(G_4.gammaInput = !0, G_4.gammaOutput = !0, G_7 = !0, !(G_8.length < 1 || G_8[0].length < 1)) {
		var o = G_8[parseInt(i / 65536) - 1][parseInt(i % 65536)].model,
			s = new GLE.Vector2;
		s.x = (t.pageX - G_4.domElement.getBoundingClientRect().left) / G_4.domElement.offsetWidth * 2 - 1, s.y = -(t.pageY - G_4.domElement.getBoundingClientRect().top) / G_4.domElement.offsetHeight * 2 + 1, G_16.sa(s, G_2);
		for(var l = [], c = 0; c < G_34.children.length; c++) o != G_34.children[c].name || "Object3D" != G_34.children[c].type && "Mesh" != G_34.children[c].type || G_34.children[c].name.indexOf("ACT_") > 0 || l.push(G_34.children[c]);
		var h = G_16.is(l, !0);
		h.length > 0 ? OnClickPosition(G_35.position.x + "," + G_35.position.y + "," + G_35.position.z + "," + G_35.rotation.x + "," + G_35.rotation.y + "," + G_35.rotation.z + "," + h[0].point.x + "," + h[0].point.y + "," + h[0].point.z) : OnClickBlank()
	}
}

function ik2(t) {
	G_7 = !1, G_4.gammaInput = !1, G_4.gammaOutput = !1;
	for(c = 0; c < G_8.length; c++)
		for(r = 0; r < G_8[c].length; r++) {
			var e = G_3.ge(G_8[c][r].model);
			if(e.material.wireframe) e.visible = !1;
			else {
				e.material = new GLE.Mal;
				G_8[c][r].color;
				e.material.color.setHex(G_8[c][r].color)
			}
		}
	G_4.sr(0, 1), G_4.render(G_3, G_2, G_6);
	var n = new Uint8Array(4);
	G_4.rls(G_6, t.pageX - G_4.domElement.getBoundingClientRect().left, G_6.height - (t.pageY - G_4.domElement.getBoundingClientRect().top), 1, 1, n);
	var i = n[0] << 16 | n[1] << 8 | n[2];
	if(0 == i) {
		G_7 = !0, G_4.sr(G_29, 1);
		for(c = 0; c < G_8.length; c++)
			for(var r = 0; r < G_8[c].length; r++) {
				var a = G_3.ge(G_8[c][r].model);
				a.material.wireframe ? a.visible = !0 : (a.material = G_11[c], a.material.color.setHex("0xffffff"))
			}
		return ShowSpace(!1), void OnClickBlank()
	}
	if(!(G_8.length < 1 || G_8[0].length < 1)) {
		var o = G_8[parseInt(i / 65536) - 1][parseInt(i % 65536)].model;
		o.indexOf("small/");
		if(o.indexOf("small/") > -1) {
			for(var s = 0, l = 0; l < G_10.length; l++)
				for(var c = 0; c < G_8[l].length; c++)
					if(G_8[l][c].model == o) {
						c,
						s = l;
						break
					}
			o = o.replace("small/", "big/");
			var h = new GLE.Gr,
				u = document.getElementById(G_10[s] + "-canvas");
			G_18 = u.getContext("2d");
			var f = new GLE.Texture(u);
			h.load(G_12[s] + o, function(t) {
				var e = t.scene.children[0];
				e.name = o, G_34.add(t.scene);
				for(var n = 0; n < G_8.length; n++)
					for(var i = 0; i < G_8[n].length; i++) {
						var r = G_3.ge(G_8[n][i].model);
						r.material = G_11[n], r.material.color.setHex("0xffffff"), G_8[n][i].model == o.replace("big/", "small/") && (G_8[n][i].model = o)
					}
				G_34.remove(G_34.ge(o.replace("big/", "small/"))), G_4.gammaInput = !0, G_4.gammaOutput = !0, G_7 = !0, G_4.sr(G_29, 1), e.traverse(function(t) {
					t instanceof GLE.Mesh && (t.name = o, t.material.map = f, t.material.map.needsUpdate = !0, t.material.transparent = !0, t.material.side = GLE.DoubleSide, t.position.x = 0, t.position.y = 0, t.position.z = 0)
				})
			})
		} else pick(o, t.pageX - G_4.domElement.getBoundingClientRect().left, t.pageY - G_4.domElement.getBoundingClientRect().top)
	}
}

function ik3(t) {
	G_7 = !1, G_4.gammaInput = !1, G_4.gammaOutput = !1;
	for(c = 0; c < G_8.length; c++)
		for(r = 0; r < G_8[c].length; r++) {
			var e = G_3.ge(G_8[c][r].model);
			if(e.material.wireframe) e.visible = !1;
			else {
				e.material = new GLE.Mal;
				G_8[c][r].color;
				e.material.color.setHex(G_8[c][r].color)
			}
		}
	G_4.sr(0, 1), G_4.render(G_3, G_2, G_6);
	var n = new Uint8Array(4);
	G_4.rls(G_6, t.pageX - G_4.domElement.getBoundingClientRect().left, G_6.height - (t.pageY - G_4.domElement.getBoundingClientRect().top), 1, 1, n);
	var i = n[0] << 16 | n[1] << 8 | n[2];
	if(0 == i) {
		G_7 = !0, G_4.gammaInput = !0, G_4.gammaOutput = !0, G_4.sr(G_29, 1);
		for(c = 0; c < G_8.length; c++)
			for(var r = 0; r < G_8[c].length; r++) {
				var a = G_3.ge(G_8[c][r].model);
				a.material.wireframe ? a.visible = !0 : (a.material = G_11[c], a.material.color.setHex("0xffffff"))
			}
		return ShowSpace(!1), void OnClickBlank()
	}
	if(!(G_8.length < 1 || G_8[0].length < 1)) {
		var o = G_8[parseInt(i / 65536) - 1][parseInt(i % 65536)].model,
			s = new GLE.Vector2;
		s.x = (t.pageX - G_4.domElement.getBoundingClientRect().left) / G_4.domElement.offsetWidth * 2 - 1, s.y = -(t.pageY - G_4.domElement.getBoundingClientRect().top) / G_4.domElement.offsetHeight * 2 + 1, G_16.sa(s, G_2);
		for(var l = [], c = 0; c < G_34.children.length; c++) o != G_34.children[c].name || "Object3D" != G_34.children[c].type && "Mesh" != G_34.children[c].type || G_34.children[c].name.indexOf("ACT_") > 0 || l.push(G_34.children[c]);
		var h = G_16.is(l, !0);
		h.length > 0 ? OnClickPosition(G_35.position.x + "," + G_35.position.y + "," + G_35.position.z + "," + G_35.rotation.x + "," + G_35.rotation.y + "," + G_35.rotation.z + "," + h[0].point.x + "," + h[0].point.y + "," + h[0].point.z) : OnClickBlank();
		o.indexOf("small/");
		if(o.indexOf("small/") > -1) {
			for(var u = 0, f = 0; f < G_10.length; f++)
				for(c = 0; c < G_8[f].length; c++)
					if(G_8[f][c].model == o) {
						c,
						u = f;
						break
					}
			o = o.replace("small/", "big/");
			var p = new GLE.Gr,
				d = document.getElementById(G_10[u] + "-canvas");
			G_18 = d.getContext("2d");
			var m = new GLE.Texture(d);
			p.load(G_12[u] + o, function(t) {
				var e = t.scene.children[0];
				e.name = o, G_34.add(t.scene);
				for(var n = 0; n < G_8.length; n++)
					for(var i = 0; i < G_8[n].length; i++) {
						var r = G_3.ge(G_8[n][i].model);
						r.material = G_11[n], r.material.color.setHex("0xffffff"), G_8[n][i].model == o.replace("big/", "small/") && (G_8[n][i].model = o)
					}
				G_34.remove(G_34.ge(o.replace("big/", "small/"))), G_4.gammaInput = !0, G_4.gammaOutput = !0, G_7 = !0, G_4.sr(G_29, 1), e.traverse(function(t) {
					t instanceof GLE.Mesh && (t.name = o, t.material.map = m, t.material.map.needsUpdate = !0, t.material.transparent = !0, t.material.side = GLE.DoubleSide, t.position.x = 0, t.position.y = 0, t.position.z = 0)
				})
			})
		} else pick(o, t.pageX - G_4.domElement.getBoundingClientRect().left, t.pageY - G_4.domElement.getBoundingClientRect().top)
	}
}

function ik4(t) {
	if(!(G_50.length > 19 && 4 == G_49 || G_50.length > 29 && 5 == G_49)) {
		G_7 = !1, G_4.gammaInput = !1, G_4.gammaOutput = !1;
		for(c = 0; c < G_8.length; c++)
			for(r = 0; r < G_8[c].length; r++) {
				var e = G_3.ge(G_8[c][r].model);
				if(e.material.wireframe) e.visible = !1;
				else {
					e.material = new GLE.Mal;
					G_8[c][r].color;
					e.material.color.setHex(G_8[c][r].color)
				}
			}
		G_4.sr(0, 1), G_4.render(G_3, G_2, G_6);
		var n = new Uint8Array(4);
		G_4.rls(G_6, t.pageX - G_4.domElement.getBoundingClientRect().left, G_6.height - (t.pageY - G_4.domElement.getBoundingClientRect().top), 1, 1, n);
		var i = n[0] << 16 | n[1] << 8 | n[2];
		if(0 == i) {
			G_7 = !0, G_4.gammaInput = !0, G_4.gammaOutput = !0, G_4.sr(G_29, 1);
			for(c = 0; c < G_8.length; c++)
				for(r = 0; r < G_8[c].length; r++)(a = G_3.ge(G_8[c][r].model)).material.wireframe ? a.visible = !0 : (a.material = G_11[c], a.material.color.setHex("0xffffff"));
			return ShowSpace(!1), void OnClickBlank()
		}
		G_4.sr(G_29, 1);
		for(c = 0; c < G_8.length; c++)
			for(var r = 0; r < G_8[c].length; r++) {
				var a = G_3.ge(G_8[c][r].model);
				a.material = G_11[c], a.material.color.setHex("0xffffff")
			}
		if(G_7 = !0, G_4.gammaInput = !0, G_4.gammaOutput = !0, !(G_8.length < 1 || G_8[0].length < 1)) {
			var o = G_8[parseInt(i / 65536) - 1][parseInt(i % 65536)].model,
				s = new GLE.Vector2;
			s.x = (t.pageX - G_4.domElement.getBoundingClientRect().left) / G_4.domElement.offsetWidth * 2 - 1, s.y = -(t.pageY - G_4.domElement.getBoundingClientRect().top) / G_4.domElement.offsetHeight * 2 + 1, G_16.sa(s, G_2);
			for(var l = [], c = 0; c < G_34.children.length; c++) o != G_34.children[c].name || "Object3D" != G_34.children[c].type && "Mesh" != G_34.children[c].type || G_34.children[c].name.indexOf("ACT_") > 0 || l.push(G_34.children[c]);
			var h = G_16.is(l, !0);
			if(h.length > 0) {
				new GLE.Geometry;
				var u = new GLE.Vector3(h[0].point.x, h[0].point.y, h[0].point.z),
					f = new GLE.Matrix4;
				u.applyMatrix4(f.getInverse(G_35.matrixWorld));
				var p = u.x,
					d = u.y,
					m = u.z;
				if(p -= G_36.position.x, d -= G_36.position.y, m -= G_36.position.z, G_50.push(new GLE.Vector3(p, d, m)), G_34.remove(G_34.ge("mypoint")), G_34.remove(G_34.ge("myline")), DrawPoints(G_50), 4 == G_49) {
					if(DrawLineSegments(G_50), G_50.length % 2 == 0) {
						var c = G_50.length / 2 - 1,
							g = new GLE.Vector3(G_50[2 * c].x, G_50[2 * c].y, G_50[2 * c].z),
							v = new GLE.Vector3(G_50[2 * c + 1].x, G_50[2 * c + 1].y, G_50[2 * c + 1].z);
						DrawWords(y = new GLE.Vector3((g.x + v.x) / 2, (g.y + v.y) / 2, (g.z + v.z) / 2), x = (g.distanceTo(v) / 1e3).toFixed(2) + "米", "result" + c)
					}
				} else if(G_50.length % 3 == 0) {
					var c = G_50.length / 3 - 1,
						g = new GLE.Vector3(G_50[3 * c].x, G_50[3 * c].y, G_50[3 * c].z),
						v = new GLE.Vector3(G_50[3 * c + 1].x, G_50[3 * c + 1].y, G_50[3 * c + 1].z),
						_ = new GLE.Vector3(G_50[3 * c + 2].x, G_50[3 * c + 2].y, G_50[3 * c + 2].z),
						y = new GLE.Vector3((g.x + v.x + _.x) / 3, (g.y + v.y + _.y) / 3, (g.z + v.z + _.z) / 3),
						x = M_GetAngle([g.x, g.y, g.z], [v.x, v.y, v.z], [_.x, _.y, _.z]).toFixed(2) + "°";
					DrawWords(y, x, "result" + c), DrawLineSegments1([g, v, _], "angle" + c)
				}
			}
		}
	}
}

function ik5(t) {
	G_7 = !1, G_4.gammaInput = !1, G_4.gammaOutput = !1;
	for(c = 0; c < G_8.length; c++)
		for(r = 0; r < G_8[c].length; r++) {
			var e = G_3.ge(G_8[c][r].model);
			if(e.material.wireframe) e.visible = !1;
			else {
				e.material = new GLE.Mal;
				G_8[c][r].color;
				e.material.color.setHex(G_8[c][r].color)
			}
		}
	G_4.sr(0, 1), G_34.ge("myline") && (G_34.ge("myline").visible = !1), G_34.ge("mytrig") && (G_34.ge("mytrig").visible = !1), G_4.render(G_3, G_2, G_6);
	var n = new Uint8Array(4);
	G_4.rls(G_6, t.pageX - G_4.domElement.getBoundingClientRect().left, G_6.height - (t.pageY - G_4.domElement.getBoundingClientRect().top), 1, 1, n);
	var i = n[0] << 16 | n[1] << 8 | n[2];
	if(G_34.ge("myline") && (G_34.ge("myline").visible = !0), G_34.ge("mytrig") && (G_34.ge("mytrig").visible = !0), 0 == i) {
		G_7 = !0, G_4.gammaInput = !0, G_4.gammaOutput = !0, G_4.sr(G_29, 1);
		for(c = 0; c < G_8.length; c++)
			for(var r = 0; r < G_8[c].length; r++) {
				var a = G_3.ge(G_8[c][r].model);
				a.material.wireframe ? a.visible = !0 : (a.material = G_11[c], a.material.color.setHex("0xffffff"))
			}
		return ShowSpace(!1), void OnClickBlank()
	}
	if(G_8[parseInt(i / 65536) - 1][parseInt(i % 65536)] && !(G_8.length < 1 || G_8[0].length < 1)) {
		var o = G_8[parseInt(i / 65536) - 1][parseInt(i % 65536)].model,
			s = new GLE.Vector2;
		s.x = (t.pageX - G_4.domElement.getBoundingClientRect().left) / G_4.domElement.offsetWidth * 2 - 1, s.y = -(t.pageY - G_4.domElement.getBoundingClientRect().top) / G_4.domElement.offsetHeight * 2 + 1, G_16.sa(s, G_2);
		for(var l = [], c = 0; c < G_34.children.length; c++) o != G_34.children[c].name || "Object3D" != G_34.children[c].type && "Mesh" != G_34.children[c].type || G_34.children[c].name.indexOf("ACT_") > 0 || l.push(G_34.children[c]);
		var h = G_16.is(l, !0);
		if(h.length > 0) {
			o.indexOf("small/");
			if(o.indexOf("small/") > -1) {
				for(var u = 0, f = 0; f < G_10.length; f++)
					for(c = 0; c < G_8[f].length; c++)
						if(G_8[f][c].model == o) {
							c,
							u = f;
							break
						}
				o = o.replace("small/", "big/");
				var p = new GLE.Gr,
					d = document.getElementById(G_10[u] + "-canvas");
				G_18 = d.getContext("2d");
				var m = new GLE.Texture(d);
				p.load(G_12[u] + o, function(t) {
					var e = t.scene.children[0];
					e.name = o, G_34.add(t.scene);
					for(var n = 0; n < G_8.length; n++)
						for(var i = 0; i < G_8[n].length; i++) {
							var r = G_3.ge(G_8[n][i].model);
							r.material = G_11[n], r.material.color.setHex("0xffffff"), G_8[n][i].model == o.replace("big/", "small/") && (G_8[n][i].model = o)
						}
					G_34.remove(G_34.ge(o.replace("big/", "small/"))), G_7 = !0, G_4.gammaInput = !0, G_4.gammaOutput = !0, G_4.sr(G_29, 1), e.traverse(function(t) {
						t instanceof GLE.Mesh && (t.name = o, t.material.map = m, t.material.map.needsUpdate = !0, t.material.transparent = !0, t.material.side = GLE.DoubleSide, t.position.x = 0, t.position.y = 0, t.position.z = 0)
					})
				})
			} else pick1(o, t.pageX - G_4.domElement.getBoundingClientRect().left, t.pageY - G_4.domElement.getBoundingClientRect().top, h[0].point.x, h[0].point.y, h[0].point.z)
		} else OnClickBlank()
	}
}

function DrawPoints(t) {
	for(var e = new GLE.Geometry, n = new GLE.PointsMaterial({
			color: 16711680,
			size: 80
		}), i = 0; i < t.length; i++) e.vertices.push(t[i]);
	var r = new GLE.Points(e, n);
	r.material.transparent = !0, r.material.side = GLE.DoubleSide, r.material.alphaTest = .1, r.material.depthTest = !1, r.material.depthWrite = !1, r.renderOrder = 10, r.name = "mypoint", G_34.add(r)
}

function DrawLineSegments(t) {
	for(var e = new GLE.Geometry, n = new GLE.LineBasicMaterial({
			color: 16711935
		}), i = 0; i < t.length; i++) e.vertices.push(t[i]);
	var r = new GLE.LineSegments(e, n);
	r.material.transparent = !0, r.material.side = GLE.DoubleSide, r.material.alphaTest = .1, r.material.depthTest = !1, r.material.depthWrite = !1, r.renderOrder = 10, r.name = "myline", G_34.add(r)
}

function DrawLineSegments1(t, e) {
	for(var n = new GLE.Geometry, i = new GLE.LineBasicMaterial({
			color: 16711935
		}), r = 0; r < t.length; r++) n.vertices.push(t[r]);
	var a = new GLE.Line(n, i);
	a.material.transparent = !0, a.material.side = GLE.DoubleSide, a.material.alphaTest = .1, a.material.depthTest = !1, a.material.depthWrite = !1, a.renderOrder = 10, a.name = e, G_34.add(a)
}

function DrawLines(t) {
	for(var e = new GLE.Geometry, n = new GLE.LineBasicMaterial({
			color: 16711935
		}), i = 0; i < t.length; i++) e.vertices.push(t[i]);
	var r = new GLE.LineLoop(e, n);
	r.material.transparent = !0, r.material.side = GLE.DoubleSide, r.material.alphaTest = .1, r.material.depthTest = !1, r.material.depthWrite = !1, r.renderOrder = 10, r.name = "myline", G_34.add(r)
}

function DrawTrigs(t) {
	for(var e = new GLE.Geometry, n = 0; n < t.length / 3; n++) e.vertices.push(t[3 * n]), e.vertices.push(t[3 * n + 1]), e.vertices.push(t[3 * n + 2]), e.faces.push(new GLE.Face3(3 * n, 3 * n + 1, 3 * n + 2));
	var i = new GLE.Mal({
		color: 255
	});
	e.computeBoundingSphere();
	var r = new GLE.Mesh(e, i);
	r.material.transparent = !0, r.material.side = GLE.DoubleSide, r.material.alphaTest = .1, r.material.depthTest = !1, r.material.depthWrite = !1, r.material.opacity = .3, r.renderOrder = 9, r.name = "mytrig", G_34.add(r)
}

function DrawWords(t, e, n) {
	var i = '<canvas id="' + n + '-canvas" height="32" width="128" style="display:block;position: absolute;top:0px;"></canvas>';
	null == G_0 ? document.getElementsByTagName("body")[0].innerHTML += i : $("#" + G_15).append(i);
	var r = document.getElementById(n + "-canvas");
	r.style.zIndex = "-1", G_18 = r.getContext("2d");
	var a = new GLE.Texture(r);
	G_18.font = "20px Arial", G_18.fillStyle = "#ff0000", G_18.textAlign = "center", G_18.fillText(e, 64, 24), a.needsUpdate = !0;
	var o = new GLE.PlaneGeometry(1e3, 320),
		s = new GLE.Mal,
		l = new GLE.Mesh(o, s);
	l.rotation.x = .5 * Math.PI, l.position.x = t.x, l.position.y = t.y, l.position.z = t.z, l.material.map = a, l.material.transparent = !0, l.material.map.needsUpdate = !0, l.material.side = GLE.DoubleSide, l.material.alphaTest = .5, l.material.depthTest = !1, l.material.depthWrite = !1, l.renderOrder = 10, l.rotation.y -= G_35.rotation.z, l.name = n, G_34.add(l)
}

function ClearMeasure() {
	G_34.remove(G_34.ge("mypoint")), G_34.remove(G_34.ge("myline")), G_34.remove(G_34.ge("area")), G_34.remove(G_34.ge("areaResult")), G_34.remove(G_34.ge("mytrig")), $("#area-canvas").remove(), $("#areaResult-canvas").remove();
	for(var t = 0; t < G_50.length / 2; t++) $("#result" + t + "-canvas").remove(), G_34.remove(G_34.ge("result" + t)), G_34.remove(G_34.ge("angle" + t));
	G_50 = []
}

function onClick(t) {
	mytime = (new Date).valueOf(), G_23 && (0 == G_49 && ik0(t), 1 == G_49 && ik1(t), 2 == G_49 && ik2(t), 3 == G_49 && ik3(t), 4 != G_49 && 5 != G_49 || ik4(t), 6 != G_49 && 7 != G_49 && 8 != G_49 && 9 != G_49 || ik5(t))
}

function AddInfo(t, e) {
	var n = t.lastIndexOf(".");
	t.substr(n + 1);
	JSZipUtils.getBinaryContent(t, function(n, i) {
		if(n) throw n;
		JSZip.loadAsync(i).then(function(e) {
			var n = t.lastIndexOf("/"),
				i = t.lastIndexOf("."),
				r = t.substr(n + 1, i - 4).replace(/info/, "json");
			return e.file(r).async("text")
		}).then(function(t) {
			for(var n = JSON.parse(t), i = 0; i < n.files.length; i++) {
				var r = "0x" + ((1 << 24) + (G_10.length << 16) + (parseInt(i / 256) << 8) + i % 256).toString(16).slice(1);
				n.files[i].color = r, G_20 && (n.files[i].model = n.files[i].model.replace("big/", "small/"))
			}
			G_8.push(n.files), G_54.push(n.names), G_92.push(n.ids);
			for(var a = JSON.parse("{}"), i = 0; i < n.files.length; i++)
				for(var o = n.names[n.files[i].name].ids.length, s = n.files[i].type, l = n.names[n.files[i].name].ids, c = 0; c < o; c++) a[l[c].id] = {
					type: s,
					status: 0
				};
			G_9.push(a), ShowSpace(!1), UpdateOrder(G_20), SetModelNomal(e), G_23 = !0, G_7 = !0, ZoomFitAll(), OnLoadModelEnd(e)
		})
	})
}

function AddModel(t, e, n) {
	if(G_23) {
		G_7 = !1;
		var i = t.lastIndexOf("/");
		G_13 = t.substr(0, i + 1);
		var r = t.lastIndexOf(".");
		t.substr(r + 1);
		$.getJSON(t, function(i) {
			if("glb" == i[0].type) {
				var r = new GLE.Lr,
					a = new GLE.Gr(r),
					o = t.indexOf("/");
				return G_131 = t.substr(0, o + 1), a.load(G_131 + i[0].model, function(t) {
					G_8.push([]), G_10.push("GLB_" + e), G_12.push(""), G_9.push([]);
					var n = t.scene;
					n.scale.x *= 1e3, n.scale.y *= 1e3, n.scale.z *= 1e3, n.rotation.x = Math.PI / 2, n.children[0].name = "GLB_" + e, G_34.add(n);
					(new GLE.Box3).st(n);
					if(G_53.min.x < .01 && G_53.min.y < .01 && G_53.min.z < .01 && G_53.max.x < .01 && G_53.max.y < .01 && G_53.max.z < .01 && (G_53 = (new GLE.Box3).st(n)), G_22) {
						var i = new GLE.Box3Helper(G_53, 16711680);
						G_34.add(i)
					}
					n.traverse(function(t) {
						t instanceof GLE.Mesh ? (t.name = "GLB_" + e, t.material.side = GLE.DoubleSide, G_11.length < G_10.length && G_11.push(t.material), G_32 = G_53.getSize().length(), G_7 = !0, ZoomFitAll()) : t.name = "GLB_" + e
					})
				}), void(r.onLoad = function() {
					G_23 = !0, OnLoadModelEnd(e)
				})
			}
			G_23 = !1, n && (G_20 = n), G_10.push(e), G_12.push(G_13);
			var s = '<canvas id="' + e + '-canvas" height="128" width="128" style="display:block;position: absolute;top:0px;"></canvas>';
			null == G_0 ? document.getElementsByTagName("body")[0].innerHTML += s : $("#" + G_15).append(s);
			var l = document.getElementById(e + "-canvas");
			l.style.zIndex = "-1", G_18 = l.getContext("2d");
			for(var c = new GLE.Texture(l), h = new GLE.Ir, u = i[0].model.split("/"), f = "", p = 0; p < 2; p++) f += u[p] + "/";
			h.load(G_13 + "color.png", function(t) {
				G_18.drawImage(t, 0, 0), c.needsUpdate = !0
			});
			for(var d = [], p = 0; p < i.length; p++) G_20 ? d.push(i[p].model.replace("big/", "small/")) : d.push(i[p].model);
			for(var r = new GLE.Lr, a = new GLE.Gr, m = 0, p = 0; p < 1; p++) {
				var g = d[p];
				a.load(G_13 + g, function(t) {
					var n = t.scene.children[0];
					if(n.name = d[0], G_55) {
						var i = new GLE.EdgesHelper(n, 2236962);
						n.add(i)
					}
					var a = (new GLE.Box3).st(n);
					if(Math.abs(G_53.min.x) < .01 && Math.abs(G_53.min.y) < .01 && Math.abs(G_53.min.z) < .01 && Math.abs(G_53.max.x) < .01 && Math.abs(G_53.max.y) < .01 && Math.abs(G_53.max.z) < .01 && (G_53 = (new GLE.Box3).st(n)), G_34.add(n), a.min.x < G_53.min.x && (G_53.min.x = a.min.x), a.min.y < G_53.min.y && (G_53.min.y = a.min.y), a.min.z < G_53.min.z && (G_53.min.z = a.min.z), a.max.x > G_53.max.x && (G_53.max.x = a.max.x), a.max.y > G_53.max.y && (G_53.max.y = a.max.y), a.max.z > G_53.max.z && (G_53.max.z = a.max.z), G_22) {
						var o = new GLE.Box3Helper(G_53, 16711680);
						G_34.add(o)
					}
					n.traverse(function(t) {
						if(t instanceof GLE.Mesh) {
							if(t.name = d[0], m++, G_11.length < G_10.length && G_11.push(t.material), t.material.map = c, t.material.map.needsUpdate = !0, t.material.transparent = !0, t.material.depthTest = !0, t.material.side = GLE.DoubleSide, 1 == d.length) return G_32 = G_53.getSize().length(), ZoomFitAll(), OnLoadModelEnd(e), G_23 = !0, void(G_7 = !0);
							r.onLoad()
						}
					})
				})
			}
			if(1 != d.length) {
				var v = 0;
				r.onLoad = function() {
					if(1 != v && 10 != v || (G_32 = G_53.getSize().length(), ZoomFitAll(), G_4.render(G_3, G_2)), 1 == d.length) return G_23 = !0, void OnLoadModelEnd(e);
					if(++v < d.length) {
						var n = d[v];
						a.load(G_13 + n, function(i) {
							var a = i.scene.children[0];
							if(a.name = n, G_55) {
								var o = new GLE.EdgesHelper(a, 2236962);
								a.add(o)
							}
							var s = (new GLE.Box3).st(a);
							if(G_34.add(a), v % 40 == 0 && G_4.render(G_3, G_2), s.min.x < G_53.min.x && (G_53.min.x = s.min.x), s.min.y < G_53.min.y && (G_53.min.y = s.min.y), s.min.z < G_53.min.z && (G_53.min.z = s.min.z), s.max.x > G_53.max.x && (G_53.max.x = s.max.x), s.max.y > G_53.max.y && (G_53.max.y = s.max.y), s.max.z > G_53.max.z && (G_53.max.z = s.max.z), G_22) new GLE.Box3Helper(s, 16711680);
							v == d.length - 1 && AddInfo(t.replace("List.json", "Info.info"), e), a.traverse(function(t) {
								t instanceof GLE.Mesh && (t.name = n, t.material.map = c, t.material.map.needsUpdate = !0, t.material.transparent = !0, t.material.depthTest = !0, t.material.side = GLE.DoubleSide)
							}), v < d.length - 1 && r.onLoad()
						})
					}
				}
			}
		})
	}
}

function SetPivot(t) {
	var e = new Array;
	if(!((e = t.toString().split(",")).length < 2)) {
		G_35.rotation.x = parseFloat(e[3]), G_35.rotation.y = parseFloat(e[4]), G_35.rotation.z = parseFloat(e[5]), G_35.position.x = parseFloat(e[0]), G_35.position.y = parseFloat(e[1]), G_35.position.z = parseFloat(e[2]), G_35.uld(!0);
		var n = new GLE.Vector3(parseFloat(e[6]), parseFloat(e[7]), parseFloat(e[8])),
			i = new GLE.Matrix4;
		n.applyMatrix4(i.getInverse(G_35.matrixWorld)), G_36.position.x -= n.x, G_36.position.y -= n.y, G_36.position.z -= n.z, G_35.position.x = parseFloat(e[6]), G_35.position.y = parseFloat(e[7]), G_35.position.z = parseFloat(e[8])
	}
}

function ZoomFitAll() {
	var t = G_53.getCenter();
	G_32 = G_53.getSize().length(), G_48.scale.x = G_32 / 1e4, G_48.scale.y = G_32 / 1e4, G_48.scale.z = G_32 / 1e4, G_2.position.copy(t), G_2.position.y -= G_32 / .8, G_2.near = G_32 / 1e4, G_2.far = 1e4 * G_32, G_2.ux(), G_2.lookAt(t), G_35.position.x = t.x, G_35.position.y = t.y, G_35.position.z = t.z, G_36.position.x = 0, G_36.position.y = 0, G_36.position.z = 0, SetPivot("0,0,0,0,0,0," + t.x + "," + t.y + "," + t.z), G_35.rotation.x = Math.PI / 4, G_35.rotation.y = 0, G_35.rotation.z = Math.PI / 4, G_56 = M_distance([G_35.position.x, G_35.position.y, G_35.position.z], [G_2.position.x, G_2.position.y, G_2.position.z])
}

function ZoomFitAll1() {
	var t = G_53.getCenter();
	G_32 = G_53.getSize().length(), G_2.position.copy(t), G_2.position.y -= G_32 / .8, G_2.near = G_32 / 1e4, G_2.far = 1e4 * G_32, G_2.ux(), G_2.lookAt(t)
}

function OnLoadSceneEnd() {}

function OnLoadModelEnd(t) {}

function OnSelectionChanged(t) {}

function OnClickPosition(t) {}

function OnClickBlank() {}

function ShowBox(t) {
	G_22 = t
}

function SetModelWireFrame(t) {
	for(var e = -1, n = 0; n < G_10.length; n++) {
		if(G_10[n] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			t instanceof GLE.Mesh && (t.material.wireframe = !0)
		});
		if(G_10[n] == t) {
			e = n;
			break
		}
	}
	if(!(e < 0))
		for(var i = G_8[e], n = 0; n < i.length; n++) {
			var r = G_3.ge(i[n].model);
			r.material = new GLE.Mal, r.material.wireframe = !0
		}
}

function SetModelNomal(t) {
	for(var e = -1, n = 0; n < G_10.length; n++) {
		if(G_10[n] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			t instanceof GLE.Mesh && (t.material.wireframe = !1)
		});
		if(G_10[n] == t) {
			e = n;
			break
		}
	}
	if(!(e < 0)) {
		for(var i = 0, n = 0; n < G_10.length; n++) G_10[n] == t && (i = n);
		for(var r = G_8[e], n = 0; n < r.length; n++) {
			var a = G_3.ge(r[n].model);
			a.material = G_11[i], a.material.wireframe = !1
		}
	}
}

function RemoveModel(t) {
	for(var e = -1, n = 0; n < G_10.length; n++) {
		if(G_10[n] == "GLB_" + t) return G_34.remove(G_34.ge("GLB_" + t)), void G_10.splice(n, 1);
		if(G_10[n] == t) {
			e = n;
			break
		}
	}
	if(!(e < 0)) {
		for(var i = G_8[e], n = 0; n < i.length; n++) G_34.remove(G_34.ge(i[n].model)), G_34.remove(G_34.ge(i[n].model.replace("big/", "small/")));
		G_10.splice(e, 1), G_11.splice(e, 1), G_12.splice(e, 1), G_8.splice(e, 1), G_9.splice(e, 1), $("#" + t + "-canvas").remove()
	}
}

function ClearScene() {
	if(G_23) {
		for(n = 0; n < G_8.length; n++)
			for(var t = 0; t < G_8[n].length; t++) {
				var e = G_34.ge(G_8[n][t].model);
				G_34.remove(e), e.geometry.dispose(), e.material.dispose()
			}
		for(var n = 0; n < G_10.length; n++) G_34.remove(G_34.ge(G_10[n])), $("#" + G_10[n] + "-canvas").remove();
		G_10 = [], G_8 = [], G_11 = [], G_12 = [], G_9 = [], G_44 = [], G_19 = !1, G_23 = !0, G_14 = [], G_54 = [], G_92 = [], (G_53 = new GLE.Box3).min.x = 0, G_53.min.y = 0, G_53.min.z = 0, G_53.max.x = 0, G_53.max.y = 0, G_53.max.z = 0, ZoomFitAll(), GLE.Cache.clear()
	}
}

function SetBackgroundImage(t) {
	return void 0 !== t && (viewer && (viewer._backImg = new Image, viewer._backImg.src = t, viewer._userAction = !0), !0)
}

function UpdateOrder(t) {
	for(var e = 0; e < G_10.length; e++)
		for(var n = 0; n < G_8[e].length; n++) {
			if("99" == G_8[e][n].type) {
				i = G_8[e][n].model;
				t && (i = i.replace("big/", "small/")), G_34.ge(i) && (G_34.ge(i).renderOrder = 1)
			}
			if("351" == G_8[e][n].type) {
				i = G_8[e][n].model;
				t && (i = i.replace("big/", "small/")), G_34.ge(i) && (G_34.ge(i).renderOrder = 4)
			}
			if("667" == G_8[e][n].type) {
				i = G_8[e][n].model;
				t && (i = i.replace("big/", "small/")), G_34.ge(i) && (G_34.ge(i).renderOrder = 3.5)
			}
			if("453" == G_8[e][n].type) {
				i = G_8[e][n].model;
				t && (i = i.replace("big/", "small/")), G_34.ge(i) && (G_34.ge(i).renderOrder = 3)
			}
			if("213" == G_8[e][n].type) {
				var i = G_8[e][n].model;
				t && (i = i.replace("big/", "small/")), G_34.ge(i) && (G_34.ge(i).renderOrder = 3)
			}
		}
	G_28 = !1, $.getJSON(jsPathstr + "token.json", function(t) {
		var e = "",
			n = "",
			i = "";
		$.each(t, function(t, r) {
			e = r.Authorization, n = r.client_id, i = r.xhrurl, $.ajax({
				type: "GET",
				url: i,
				async: !0,
				data: "Authorization=bearer " + e + "&client_id=" + n + "&from_Type=webpage",
				success: function(t) {
					if("100" != t ){
						alert("此软件未授权或授权过期，已破解");
					}
					G_28=true;
					
					//"100" == t ? G_28 = !0 : (G_28 = !1, alert("未授权或授权过期!"))
				},
				error: function(t) {
					alert("访问授权失败，已解决");
					G_28=true;
					//G_28 = !1, alert("未授权或授权过期!")
				}
			})
		})
	})
}

function ShowSpace(t) {
	for(var e = 0; e < G_10.length; e++)
		for(var n = 0; n < G_8[e].length; n++)
			if("454" == G_8[e][n].type) {
				var i = G_8[e][n].model;
				G_20 && (i = i.replace("big/", "small/")), G_34.ge(i) && (G_34.ge(i).visible = !1, G_34.ge(i).visible = t)
			}
}

function SetActorColor(t, e, n, i, r) {
	var a = new Array;
	a = t.toString().split("_");
	for(var o = 0, s = 0; s < G_10.length; s++) G_10[s] == a[0] && (o = s);
	var l = GetTypeById(t);
	if(-1 == l) return -1;
	G_19 = !0;
	for(var c = [], s = 0; s < G_8[o].length; s++) {
		for(var h = 0, u = 0; u < G_54[o][G_8[o][s].name].ids.length; u++)
			if(G_54[o][G_8[o][s].name].ids[u].id == a[1]) {
				h++;
				break
			}
		h > 0 && G_8[o][s].type == l && c.push(G_8[o][s])
	}
	G_14.push([e, n, i, 255]);
	var f = document.getElementById(a[0] + "-canvas");
	(G_18 = f.getContext("2d")).fillStyle = "rgba(" + e + "," + n + "," + i + ",1.0)", G_18.fillRect(G_14.length - 1, 127, 1, 1);
	for(var p = 1 / 256 + (G_14.length - 1) / 128, d = "", m = 0; m < c.length; m++) {
		d = "", m1 = c[m].model;
		for(var g = m1.split("/"), s = 0; s < g.length - 1; s++) d += g[s] + "/";
		d += g[g.length - 2] + ".info"
	}
	for(m = 0; m < c.length; m++) {
		m1 = c[m].model;
		for(var v = G_3.ge(m1), g = m1.split("/"), _ = 0, s = 0; s < G_8[o].length; s++)
			if(G_8[o][s].model == m1) {
				s;
				break
			}
		for(s = 0; s < G_8[o].length; s++) G_8[o][s].model.indexOf("/" + g[g.length - 2] + "/") > 0 && _++;
		var y = [];
		y.push(a[1]);
		var x = parseInt(g[g.length - 1].replace(".glb", "").replace(g[g.length - 2], "")),
			b = 65535 * x,
			w = 65535 * x;
		w = 65535 * x + v.geometry.attributes.position.count - 1;
		for(s = 0; s < y.length; s++)
			for(var M = G_92[o][y[s]], u = 0; u < M.indices.length; u++) {
				var S = parseInt(M.indices[u].start),
					G = parseInt(M.indices[u].end);
				if(!(S > w || G < b)) {
					var E = b,
						T = w;
					S > b - 1 && (E = S), G < w + 1 && (T = G);
					for(var A = E - 65535 * x; A < T + 1 - 65535 * x; A++) v.geometry.attributes.uv.array[2 * A] = p, v.geometry.attributes.uv.array[2 * A + 1] = 1 / 256
				}
			}
		G_9[o][a[1]].status = 1, v.geometry.attributes.uv.needsUpdate = !0, v.material.map.needsUpdate = !0;
		for(var L = !0, s = 0; s < G_44.length; s++)
			if(G_44[s][0] == a[0] && G_44[s][1] == a[1] && 1 == G_44[s][2]) {
				L = !1;
				break
			}!r && L && G_44.push([a[0], a[1], 1, e, n, i])
	}
	G_19 = !1
}

function SetActorAlpha(t, e) {
	G_19 = !0;
	var n = new Array;
	n = t.toString().split("_");
	for(var i = 0, r = 0; r < G_10.length; r++) G_10[r] == n[0] && (i = r);
	var a = GetTypeById(t);
	if(-1 == a) return -1;
	for(var o = [], r = 0; r < G_8[i].length; r++) {
		for(var s = 0, l = 0; l < G_54[i][G_8[i][r].name].ids.length; l++)
			if(G_54[i][G_8[i][r].name].ids[l].id == n[1]) {
				s++;
				break
			}
		s > 0 && G_8[i][r].type == a && o.push(G_8[i][r])
	}
	for(var c = "", h = 0; h < o.length; h++) {
		c = "", m1 = o[h].model;
		for(var u = m1.split("/"), r = 0; r < u.length - 1; r++) c += u[r] + "/";
		c += u[u.length - 2] + ".info"
	}
	for(h = 0; h < o.length; h++) {
		m1 = o[h].model;
		for(var f = G_3.ge(m1), u = m1.split("/"), p = 0, r = 0; r < G_8[i].length; r++)
			if(G_8[i][r].model == m1) {
				r;
				break
			}
		for(r = 0; r < G_8[i].length; r++) G_8[i][r].model.indexOf("/" + u[u.length - 2] + "/") > 0 && p++;
		var d = [];
		d.push(n[1]);
		var m = parseInt(u[u.length - 1].replace(".glb", "").replace(u[u.length - 2], "")),
			g = 65535 * m,
			v = 65535 * m;
		v = 65535 * m + f.geometry.attributes.position.count - 1;
		for(r = 0; r < d.length; r++)
			for(var _ = G_92[i][d[r]], l = 0; l < _.indices.length; l++) {
				var y = parseInt(_.indices[l].start),
					x = parseInt(_.indices[l].end);
				if(!(y > v || x < g)) {
					var b = g,
						w = v;
					y > g - 1 && (b = y), x < v + 1 && (w = x);
					for(var M = b - 65535 * m; M < w + 1 - 65535 * m; M++) f.geometry.attributes.uv.array[2 * M] = parseFloat(_.indices[l].type_u), f.geometry.attributes.uv.array[2 * M + 1] = parseFloat(_.indices[l].type_v), f.geometry.attributes.uv.array[2 * M + 1] > .984375 && (f.geometry.attributes.uv.array[2 * M + 1] = 1 - (1.5 - e) / 128)
				}
			}
		G_9[i][n[1]].status = 2, f.geometry.attributes.uv.needsUpdate = !0, f.material.map.needsUpdate = !0;
		for(r = 0; r < G_44.length; r++)
			if(G_44[r][0] == n[0] && G_44[r][1] == n[1]) {
				!1;
				break
			}
		G_44.push([n[0], n[1], 2, e]), f.renderOrder = 1
	}
	G_19 = !1
}

function SetActorVisible(t, e) {
	G_19 = !0;
	var n = new Array;
	n = t.toString().split("_");
	for(var i = 0, r = 0; r < G_10.length; r++) G_10[r] == n[0] && (i = r);
	var a = GetTypeById(t);
	if(-1 == a) return -1;
	for(var o = [], r = 0; r < G_8[i].length; r++) {
		for(var s = 0, l = 0; l < G_54[i][G_8[i][r].name].ids.length; l++)
			if(G_54[i][G_8[i][r].name].ids[l].id == n[1]) {
				s++;
				break
			}
		s > 0 && G_8[i][r].type == a && o.push(G_8[i][r])
	}
	for(var c = "", h = 0; h < o.length; h++) {
		c = "", m1 = o[h].model;
		for(var u = m1.split("/"), r = 0; r < u.length - 1; r++) c += u[r] + "/";
		c += u[u.length - 2] + ".info"
	}
	for(h = 0; h < o.length; h++) {
		m1 = o[h].model;
		for(var f = G_3.ge(m1), u = m1.split("/"), p = 0, r = 0; r < G_8[i].length; r++)
			if(G_8[i][r].model == m1) {
				r;
				break
			}
		for(r = 0; r < G_8[i].length; r++) G_8[i][r].model.indexOf("/" + u[u.length - 2] + "/") > 0 && p++;
		var d = [];
		d.push(n[1]);
		var m = parseInt(u[u.length - 1].replace(".glb", "").replace(u[u.length - 2], "")),
			g = 65535 * m,
			v = 65535 * m;
		v = 65535 * m + f.geometry.attributes.position.count - 1;
		for(r = 0; r < d.length; r++)
			for(var _ = G_92[i][d[r]], l = 0; l < _.indices.length; l++) {
				var y = parseInt(_.indices[l].start),
					x = parseInt(_.indices[l].end);
				if(!(y > v || x < g)) {
					var b = g,
						w = v;
					y > g - 1 && (b = y), x < v + 1 && (w = x);
					for(var M = b - 65535 * m; M < w + 1 - 65535 * m; M++) {
						var S = f.geometry.attributes.position.array;
						e && 3 == G_9[i][n[1]].status && (S[3 * M] *= 1e6, S[3 * M + 1] *= 1e6, S[3 * M + 2] *= 1e6), e || 3 == G_9[i][n[1]].status || (S[3 * M] /= 1e6, S[3 * M + 1] /= 1e6, S[3 * M + 2] /= 1e6)
					}
				}
			}
		f.geometry.attributes.position.needsUpdate = !0
	}
	if(e) {
		G_9[i][n[1]].status = 0;
		for(r = 0; r < G_44.length; r++) G_44[r][0] == n[0] && G_44[r][1] == n[1] && G_44.splice(r, 1)
	} else {
		G_9[i][n[1]].status = 3;
		for(r = 0; r < G_44.length; r++)
			if(G_44[r][0] == n[0] && G_44[r][1] == n[1]) {
				!1, 3 != G_44[r][2] && (G_44[r][2] = 3);
				break
			}
		G_44.push([n[0], n[1], 3])
	}
	G_19 = !1
}

function ResetPopOut(t) {
	var e = new Array;
	e = t.toString().split("_");
	for(var n = 0, i = -1, r = 0; r < G_46.length; r++)
		if(e[0] == G_46[r][0] && e[1] == G_46[r][1]) {
			i = r, n++;
			break
		}
	if(0 != n) {
		G_46.splice(i, 1);
		for(var a = 0, r = 0; r < G_10.length; r++) G_10[r] == e[0] && (a = r);
		var o = GetTypeById(t);
		if(-1 == o) return -1;
		for(var s = [], r = 0; r < G_8[a].length; r++) {
			for(var l = 0, c = 0; c < G_54[a][G_8[a][r].name].ids.length; c++)
				if(G_54[a][G_8[a][r].name].ids[c].id == e[1]) {
					l++;
					break
				}
			l > 0 && G_8[a][r].type == o && s.push(G_8[a][r])
		}
		var h = document.getElementById(e[0] + "-canvas");
		G_18 = h.getContext("2d");
		for(var u = "", f = 0; f < s.length; f++) {
			u = "", m1 = s[f].model;
			for(var p = m1.split("/"), r = 0; r < p.length - 1; r++) u += p[r] + "/";
			u += p[p.length - 2] + ".info"
		}
		for(f = 0; f < s.length; f++) {
			m1 = s[f].model;
			for(var d = G_3.ge(m1), p = m1.split("/"), m = 0, r = 0; r < G_8[a].length; r++)
				if(G_8[a][r].model == m1) {
					r;
					break
				}
			for(r = 0; r < G_8[a].length; r++) G_8[a][r].model.indexOf("/" + p[p.length - 2] + "/") > 0 && m++;
			var g = [];
			g.push(e[1]);
			var v = parseInt(p[p.length - 1].replace(".glb", "").replace(p[p.length - 2], "")),
				_ = 65535 * v,
				y = 65535 * v;
			y = 65535 * v + d.geometry.attributes.position.count - 1;
			for(r = 0; r < g.length; r++)
				for(var x = G_92[a][g[r]], b = x.box_0 + x.box_3 / 2, w = x.box_1 + x.box_4 / 2, M = x.box_2 + x.box_5 / 2, c = 0; c < x.indices.length; c++) {
					var S = parseInt(x.indices[c].start),
						G = parseInt(x.indices[c].end);
					if(!(S > y || G < _)) {
						var E = _,
							T = y;
						S > _ - 1 && (E = S), G < y + 1 && (T = G);
						for(var A = E - 65535 * v; A < T + 1 - 65535 * v; A++) {
							var L = d.geometry.attributes.position.array;
							L[3 * A] -= .3 * b, L[3 * A + 1] -= .3 * w, L[3 * A + 2] -= .3 * M
						}
					}
				}
			d.geometry.attributes.position.needsUpdate = !0
		}
	}
}

function PopOut(t, e) {
	var n = new Array;
	n = t.toString().split("_"), e = .3;
	for(r = 0; r < G_46.length; r++)
		if(n[0] == G_46[r][0] && n[1] == G_46[r][1]) return;
	G_46.push([n[0], n[1]]);
	for(var i = 0, r = 0; r < G_10.length; r++) G_10[r] == n[0] && (i = r);
	var a = GetTypeById(t);
	if(-1 == a) return -1;
	for(var o = [], r = 0; r < G_8[i].length; r++) {
		for(var s = 0, l = 0; l < G_54[i][G_8[i][r].name].ids.length; l++)
			if(G_54[i][G_8[i][r].name].ids[l].id == n[1]) {
				s++;
				break
			}
		s > 0 && G_8[i][r].type == a && o.push(G_8[i][r])
	}
	var c = document.getElementById(n[0] + "-canvas");
	G_18 = c.getContext("2d");
	for(var h = "", u = 0; u < o.length; u++) {
		h = "", m1 = o[u].model;
		for(var f = m1.split("/"), r = 0; r < f.length - 1; r++) h += f[r] + "/";
		h += f[f.length - 2] + ".info"
	}
	for(u = 0; u < o.length; u++) {
		m1 = o[u].model;
		for(var p = G_3.ge(m1), f = m1.split("/"), d = 0, r = 0; r < G_8[i].length; r++)
			if(G_8[i][r].model == m1) {
				r;
				break
			}
		for(r = 0; r < G_8[i].length; r++) G_8[i][r].model.indexOf("/" + f[f.length - 2] + "/") > 0 && d++;
		var m = [];
		m.push(n[1]);
		var g = parseInt(f[f.length - 1].replace(".glb", "").replace(f[f.length - 2], "")),
			v = 65535 * g,
			_ = 65535 * g;
		_ = 65535 * g + p.geometry.attributes.position.count - 1;
		for(r = 0; r < m.length; r++)
			for(var y = G_92[i][m[r]], x = y.box_0 + y.box_3 / 2, b = y.box_1 + y.box_4 / 2, w = y.box_2 + y.box_5 / 2, l = 0; l < y.indices.length; l++) {
				var M = parseInt(y.indices[l].start),
					S = parseInt(y.indices[l].end);
				if(!(M > _ || S < v)) {
					var G = v,
						E = _;
					M > v - 1 && (G = M), S < _ + 1 && (E = S);
					for(var T = G - 65535 * g; T < E + 1 - 65535 * g; T++) {
						var A = p.geometry.attributes.position.array;
						A[3 * T] += x * e, A[3 * T + 1] += b * e, A[3 * T + 2] += w * e
					}
				}
			}
		p.geometry.attributes.position.needsUpdate = !0
	}
}

function M_normalize(t, e) {
	var n = e[0],
		i = e[1],
		r = e[2],
		a = n * n + i * i + r * r;
	return a > 0 && (a = 1 / Math.sqrt(a), t[0] = e[0] * a, t[1] = e[1] * a, t[2] = e[2] * a), t
}

function M_dot(t, e) {
	return t[0] * e[0] + t[1] * e[1] + t[2] * e[2]
}

function M_cross(t, e, n) {
	var i = e[0],
		r = e[1],
		a = e[2],
		o = n[0],
		s = n[1],
		l = n[2];
	return t[0] = r * l - a * s, t[1] = a * o - i * l, t[2] = i * s - r * o, t
}

function M_subtract(t, e, n) {
	return t[0] = e[0] - n[0], t[1] = e[1] - n[1], t[2] = e[2] - n[2], t
}

function M_JudgePlane(t, e, n, i) {
	var r = [0, 0, 0];
	M_subtract(r, e, t);
	var a = [0, 0, 0];
	M_subtract(a, n, e);
	var o = [0, 0, 0];
	M_cross(o, r, a);
	var s = [0, 0, 0];
	M_normalize(s, o);
	var l = M_dot(t, s);
	return Math.abs(M_dot(i, s) - l) < .01
}

function M_distance(t, e) {
	var n = e[0] - t[0],
		i = e[1] - t[1],
		r = e[2] - t[2];
	return Math.sqrt(n * n + i * i + r * r)
}

function M_GetArea(t, e, n) {
	var i = M_distance(t, e),
		r = M_distance(t, n),
		a = M_distance(e, n),
		o = (i + r + a) / 2;
	return Math.sqrt(o * (o - i) * (o - r) * (o - a))
}

function M_GetAngle(t, e, n) {
	var i = M_distance(t, e),
		r = M_distance(t, n),
		a = M_distance(e, n);
	return 180 * Math.acos((i * i + a * a - r * r) / (2 * i * a)) / 3.1415926
}

function pick1(t, e, n, i, r, a) {
	G_7 = !1;
	var o;
	G_3.ge(t);
	(o = G_3.ge(t)).name = t;
	for(var s = t.split("/"), l = 0, c = 0, h = 0, u = 0; u < G_10.length; u++)
		for(d = 0; d < G_8[u].length; d++)
			if(G_8[u][d].model == t) {
				h = d, c = u;
				break
			}
	for(d = 0; d < G_8[c].length; d++) G_8[c][d].model.indexOf("/" + s[s.length - 2] + "/") > 0 && l++;
	for(var f = "", p = "", d = 0; d < s.length - 1; d++) f += s[d] + "/", p += s[d] + "/";
	f += s[s.length - 2] + ".info", p += "idcolor.png";
	for(var m = [], d = 0; d < G_54[c][G_8[c][h].name].ids.length; d++) m.push(G_54[c][G_8[c][h].name].ids[d].id);
	var g = parseInt(s[s.length - 1].replace(".glb", "").replace(s[s.length - 2], "")),
		v = 65535 * g,
		_ = 65535 * g;
	_ = 65535 * g + o.geometry.attributes.position.count - 1;
	for(d = 0; d < m.length; d++)
		for(var y = G_92[c][m[d]], x = parseFloat(y.id_u), b = parseFloat(y.id_v), w = 0; w < y.indices.length; w++) {
			var M = parseInt(y.indices[w].start),
				S = parseInt(y.indices[w].end);
			if(!(M > _ || S < v)) {
				var G = v,
					E = _;
				M > v - 1 && (G = M), S < _ + 1 && (E = S);
				for(var T = G - 65535 * g; T < E + 1 - 65535 * g; T++) o.geometry.attributes.uv.array[2 * T] = x, o.geometry.attributes.uv.array[2 * T + 1] = b
			}
		}
	var A = new GLE.Texture;
	(new GLE.Ir).load(G_12[c] + p, function(t) {
		A.image = t, A.needsUpdate = !0, o.material = new GLE.Mal, o.material.map = A, o.material.map.needsUpdate = !0, o.geometry.attributes.uv.needsUpdate = !0, G_4.sr(0, 1), G_34.ge("mytrig") && (G_34.ge("mytrig").visible = !1), G_4.render(G_3, G_2, G_6);
		var s = new Uint8Array(4);
		G_4.rls(G_6, e, G_6.height - n, 1, 1, s);
		var l = s[0] << 16 | s[1] << 8 | s[2];
		G_34.ge("mytrig") && (G_34.ge("mytrig").visible = !0);
		var h = new GLE.Vector3(i, r, a),
			u = new GLE.Matrix4;
		h.applyMatrix4(u.getInverse(G_35.matrixWorld));
		var f = h.x,
			p = h.y,
			d = h.z;
		f -= G_36.position.x, p -= G_36.position.y, d -= G_36.position.z;
		for(var y = [], x = 0; x < m.length; x++) {
			parseInt(m[x]) % 16777216 == l && (l = parseInt(m[x]));
			for(var b = G_92[c][m[x]], w = 0; w < b.indices.length; w++) {
				var M = parseInt(b.indices[w].start),
					S = parseInt(b.indices[w].end);
				if(!(M > _ || S < v)) {
					var G = v,
						E = _;
					M > v - 1 && (G = M), S < _ + 1 && (E = S);
					for(var T = G - 65535 * g; T < E + 1 - 65535 * g; T++) {
						o.geometry.attributes.uv.array[2 * T] = parseFloat(b.indices[w].type_u), o.geometry.attributes.uv.array[2 * T + 1] = parseFloat(b.indices[w].type_v);
						var h = new GLE.Vector3(o.geometry.attributes.position.array[3 * T], o.geometry.attributes.position.array[3 * T + 1], o.geometry.attributes.position.array[3 * T + 2]),
							L = (new GLE.Matrix4, new GLE.Vector3(1, 0, 0)),
							C = Math.PI / 2;
						h.applyAxisAngle(L, C);
						var P = h.x,
							I = h.y,
							R = h.z;
						l == parseInt(m[x]) && y.push(new GLE.Vector3(P, I, R))
					}
				}
			}
		}
		if(6 == G_49) {
			for(var O = [], N = 0, x = 0; x < y.length / 3; x++)(V = M_JudgePlane([y[3 * x].x, y[3 * x].y, y[3 * x].z], [y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z], [y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z], [f, p, d])) && (O.push(new GLE.Vector3(y[3 * x].x, y[3 * x].y, y[3 * x].z)), O.push(new GLE.Vector3(y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z)), O.push(new GLE.Vector3(y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z)), N += M_GetArea([y[3 * x].x, y[3 * x].y, y[3 * x].z], [y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z], [y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z]));
			G_34.remove(G_34.ge("areaResult")), G_34.remove(G_34.ge("mytrig")), G_34.remove(G_34.ge("area")), $("#area-canvas").remove(), $("#areaResult-canvas").remove(), DrawTrigs(O);
			for(var D = new GLE.Vector3(0, 0, 0), z = 0, U = 0, F = 0, x = 0; x < O.length; x++) z += O[x].x, U += O[x].y, F += O[x].z;
			D.x = z / O.length, D.y = U / O.length, D.z = F / O.length, DrawWords(D, j = (parseFloat(N) / 1e6).toFixed(2) + "平方米", "areaResult")
		}
		if(7 == G_49) {
			for(var O = [], N = 0, x = 0; x < y.length / 3; x++)(V = !0) && (O.push(new GLE.Vector3(y[3 * x].x, y[3 * x].y, y[3 * x].z)), O.push(new GLE.Vector3(y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z)), O.push(new GLE.Vector3(y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z)), N += M_GetArea([y[3 * x].x, y[3 * x].y, y[3 * x].z], [y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z], [y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z]));
			G_34.remove(G_34.ge("areaResult")), G_34.remove(G_34.ge("mytrig")), G_34.remove(G_34.ge("area")), $("#area-canvas").remove(), $("#areaResult-canvas").remove(), DrawTrigs(O);
			for(var D = new GLE.Vector3(0, 0, 0), z = 0, U = 0, F = 0, x = 0; x < O.length; x++) z += O[x].x, U += O[x].y, F += O[x].z;
			D.x = z / O.length, D.y = U / O.length, D.z = F / O.length, DrawWords(D, j = (parseFloat(N) / 1e6).toFixed(2) + "平方米", "areaResult")
		}
		if(8 == G_49) {
			for(var O = [], x = 0; x < y.length / 3; x++)(V = !0) && (O.push(new GLE.Vector3(y[3 * x].x, y[3 * x].y, y[3 * x].z)), O.push(new GLE.Vector3(y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z)), O.push(new GLE.Vector3(y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z)));
			G_34.remove(G_34.ge("areaResult")), G_34.remove(G_34.ge("mytrig")), G_34.remove(G_34.ge("area")), $("#area-canvas").remove(), $("#areaResult-canvas").remove(), DrawTrigs(O);
			for(var D = new GLE.Vector3(0, 0, 0), k = new GLE.Vector3(O[0].x, O[0].y, O[0].z), B = new GLE.Vector3(O[0].x, O[0].y, O[0].z), z = 0, U = 0, F = 0, x = 0; x < O.length; x++) z += O[x].x, U += O[x].y, F += O[x].z, O[x].x < k.x && (k.x = O[x].x), O[x].y < k.y && (k.y = O[x].y), O[x].z < k.z && (k.z = O[x].z), O[x].x > B.x && (B.x = O[x].x), O[x].y > B.y && (B.y = O[x].y), O[x].z > B.z && (B.z = O[x].z);
			D.x = z / O.length, D.y = U / O.length, D.z = F / O.length, DrawWords(D, j = (parseFloat((B.x - k.x) * (B.y - k.y) * (B.z - k.z)) / 1e9).toFixed(2) + "立方米", "areaResult")
		}
		if(9 == G_49) {
			for(var O = [], x = 0; x < y.length / 3; x++) {
				var V = !0;
				V && (O.push(new GLE.Vector3(y[3 * x].x, y[3 * x].y, y[3 * x].z)), O.push(new GLE.Vector3(y[3 * x + 1].x, y[3 * x + 1].y, y[3 * x + 1].z)), O.push(new GLE.Vector3(y[3 * x + 2].x, y[3 * x + 2].y, y[3 * x + 2].z)))
			}
			G_34.remove(G_34.ge("areaResult")), G_34.remove(G_34.ge("mytrig")), G_34.remove(G_34.ge("area")), $("#area-canvas").remove(), $("#areaResult-canvas").remove(), DrawTrigs(O);
			for(var D = new GLE.Vector3(0, 0, 0), k = new GLE.Vector3(O[0].x, O[0].y, O[0].z), B = new GLE.Vector3(O[0].x, O[0].y, O[0].z), z = 0, U = 0, F = 0, x = 0; x < O.length; x++) z += O[x].x, U += O[x].y, F += O[x].z, O[x].x < k.x && (k.x = O[x].x), O[x].y < k.y && (k.y = O[x].y), O[x].z < k.z && (k.z = O[x].z), O[x].x > B.x && (B.x = O[x].x), O[x].y > B.y && (B.y = O[x].y), O[x].z > B.z && (B.z = O[x].z);
			D.x = z / O.length, D.y = U / O.length, D.z = F / O.length;
			var j = (G_52 / 1e3 * parseFloat((B.x - k.x) * (B.y - k.y) * (B.z - k.z)) / 1e9).toFixed(2) + "吨";
			DrawWords(D, j, "areaResult")
		}
		var H = document.getElementById(G_10[c] + "-canvas");
		G_18 = H.getContext("2d");
		for(var W = new GLE.Texture(H), X = 0, x = 0; x < G_10.length; x++) G_10[x] == G_10[c] && (X = x);
		o.material = G_11[X], o.material.map = W, o.material.map.needsUpdate = !0, o.material.transparent = !0, o.material.side = GLE.DoubleSide, o.geometry.attributes.uv.needsUpdate = !0, o.geometry.attributes.position.needsUpdate = !0, G_4.sr(G_29, 1);
		for(x = 0; x < G_8.length; x++)
			for(w = 0; w < G_8[x].length; w++) {
				var Y = G_3.ge(G_8[x][w].model);
				Y.material = G_11[x], Y.material.color.setHex("0xffffff")
			}
		if(l > 0) {
			for(var q = [], x = G_44.length - 1; x > -1; x--) {
				for(var Z = 0, w = 0; w < q.length; w++)
					if(G_44[x][0] == q[w][0] && G_44[x][1] == q[w][1]) {
						Z++, myindex = x;
						break
					}
				0 == Z && q.push(G_44[x])
			}
			for(x = 0; x < q.length; x++)
				for(w = 0; w < m.length; w++) q[x][1] == m[w] && (G_17 || 1 != q[x][2] || SetActorColor(q[x][0] + "_" + q[x][1], q[x][3], q[x][4], q[x][5], !0), 2 == q[x][2] && SetActorAlpha(q[x][0] + "_" + q[x][1], q[x][3]));
			G_7 = !0
		}
	})
}

function pick(t, e, n) {
	G_7 = !1;
	var i;
	G_3.ge(t);
	(i = G_3.ge(t)).name = t;
	for(var r = t.split("/"), a = 0, o = 0, s = 0, l = 0; l < G_10.length; l++)
		for(u = 0; u < G_8[l].length; u++)
			if(G_8[l][u].model == t) {
				s = u, o = l;
				break
			}
	for(u = 0; u < G_8[o].length; u++) G_8[o][u].model.indexOf("/" + r[r.length - 2] + "/") > 0 && a++;
	for(var c = "", h = "", u = 0; u < r.length - 1; u++) c += r[u] + "/", h += r[u] + "/";
	c += r[r.length - 2] + ".info", h += "idcolor.png";
	for(var f = [], u = 0; u < G_54[o][G_8[o][s].name].ids.length; u++) f.push(G_54[o][G_8[o][s].name].ids[u].id);
	var p = parseInt(r[r.length - 1].replace(".glb", "").replace(r[r.length - 2], "")),
		d = 65535 * p,
		m = 65535 * p;
	m = 65535 * p + i.geometry.attributes.position.count - 1;
	for(u = 0; u < f.length; u++)
		for(var g = G_92[o][f[u]], v = parseFloat(g.id_u), _ = parseFloat(g.id_v), y = 0; y < g.indices.length; y++) {
			var x = parseInt(g.indices[y].start),
				b = parseInt(g.indices[y].end);
			if(!(x > m || b < d)) {
				var w = d,
					M = m;
				x > d - 1 && (w = x), b < m + 1 && (M = b);
				for(var S = w - 65535 * p; S < M + 1 - 65535 * p; S++) i.geometry.attributes.uv.array[2 * S] = v, i.geometry.attributes.uv.array[2 * S + 1] = _
			}
		}
	var G = new GLE.Texture;
	(new GLE.Ir).load(G_12[o] + h, function(t) {
		G.image = t, G.needsUpdate = !0, i.material = new GLE.Mal, i.material.map = G, i.material.map.needsUpdate = !0, i.geometry.attributes.uv.needsUpdate = !0, G_4.sr(0, 1), ShowAllAnchor(!1), G_4.render(G_3, G_2, G_6);
		var r = new Uint8Array(4);
		G_4.rls(G_6, e, G_6.height - n, 1, 1, r);
		var a = r[0] << 16 | r[1] << 8 | r[2];
		ShowAllAnchor(!0);
		for(b = 0; b < f.length; b++) {
			parseInt(f[b]) % 16777216 == a && (a = parseInt(f[b]));
			for(var s = G_92[o][f[b]], l = 0; l < s.indices.length; l++) {
				var c = parseInt(s.indices[l].start),
					h = parseInt(s.indices[l].end);
				if(!(c > m || h < d)) {
					var u = d,
						g = m;
					c > d - 1 && (u = c), h < m + 1 && (g = h);
					for(var v = u - 65535 * p; v < g + 1 - 65535 * p; v++) i.geometry.attributes.uv.array[2 * v] = parseFloat(s.indices[l].type_u), i.geometry.attributes.uv.array[2 * v + 1] = parseFloat(s.indices[l].type_v)
				}
			}
		}
		var _ = document.getElementById(G_10[o] + "-canvas");
		G_18 = _.getContext("2d");
		for(var y = new GLE.Texture(_), x = 0, b = 0; b < G_10.length; b++) G_10[b] == G_10[o] && (x = b);
		i.material = G_11[x], i.material.map = y, i.material.map.needsUpdate = !0, i.material.transparent = !0, i.material.side = GLE.DoubleSide, i.geometry.attributes.uv.needsUpdate = !0, G_4.sr(G_29, 1);
		for(b = 0; b < G_8.length; b++)
			for(l = 0; l < G_8[b].length; l++) {
				var w = G_3.ge(G_8[b][l].model);
				w.material = G_11[b], w.material.color.setHex("0xffffff")
			}
		if(a > 0) {
			for(var M = [], b = G_44.length - 1; b > -1; b--) {
				for(var S = 0, l = 0; l < M.length; l++)
					if(G_44[b][0] == M[l][0] && G_44[b][1] == M[l][1]) {
						S++, myindex = b;
						break
					}
				0 == S && M.push(G_44[b])
			}
			for(b = 0; b < M.length; b++)
				for(l = 0; l < f.length; l++) M[b][1] == f[l] && (G_17 || 1 != M[b][2] || SetActorColor(M[b][0] + "_" + M[b][1], M[b][3], M[b][4], M[b][5], !0), 2 == M[b][2] && SetActorAlpha(M[b][0] + "_" + M[b][1], M[b][3]));
			G_7 = !0, OnSelectionChanged(G_10[o] + "_" + a)
		}
	})
}

function SetSelectState(t) {
	G_17 = t
}

function SetViewPort(t) {
	ZoomFitAll(), "top" == t ? (G_35.rotation.x = Math.PI / 2, G_35.rotation.y = 0, G_35.rotation.z = 0) : "bottom" == t ? (G_35.rotation.x = -Math.PI / 2, G_35.rotation.y = 0, G_35.rotation.z = 0) : "front" == t ? (G_35.rotation.x = 0, G_35.rotation.y = 0, G_35.rotation.z = 0) : "back" == t ? (G_35.rotation.x = 0, G_35.rotation.y = 0, G_35.rotation.z = Math.PI) : "left" == t ? (G_35.rotation.x = 0, G_35.rotation.y = 0, G_35.rotation.z = Math.PI / 2) : "right" == t && (G_35.rotation.x = 0, G_35.rotation.y = 0, G_35.rotation.z = -Math.PI / 2)
}

function AddAnchor(t, e, n, i, r) {
	var a = G_35.position.x,
		o = G_35.position.y,
		s = G_35.position.z,
		l = G_35.rotation.x,
		c = G_35.rotation.y,
		h = G_35.rotation.z,
		u = new Array;
	SetCamera((u = t.toString().split(","))[0] + "," + u[1] + "," + u[2] + "," + u[3] + "," + u[4] + "," + u[5]), render();
	var f = new GLE.Vector3(parseFloat(u[6]), parseFloat(u[7]), parseFloat(u[8])),
		p = new GLE.Matrix4;
	f.applyMatrix4(p.getInverse(G_35.matrixWorld));
	G_35.position.x, G_35.position.y, G_35.position.z, G_35.rotation.x, G_35.rotation.y, G_35.rotation.z;
	var d = new GLE.By(0, 0, 0),
		m = new GLE.Mal({
			color: 16711680
		}),
		g = (new GLE.Mesh(d, m), new GLE.Mesh(d, m), (new GLE.TextureLoader).load(e)),
		v = new GLE.PlaneGeometry(1e3 * n, 1e3 * i),
		_ = new GLE.Mal,
		y = new GLE.Mesh(v, _);
	y.rotation.x = .5 * Math.PI, y.position.x = f.x, y.position.y = f.y, y.position.z = f.z, y.position.x -= G_36.position.x, y.position.y -= G_36.position.y, y.position.z -= G_36.position.z, y.material.map = g, y.material.transparent = !0, y.material.map.needsUpdate = !0, y.material.side = GLE.DoubleSide, y.material.alphaTest = .5, y.material.depthTest = !1, y.material.depthWrite = !1, y.renderOrder = 10, y.rotation.y -= G_35.rotation.z, y.name = "ACT_" + r, G_34.add(y), G_35.position.x = a, G_35.position.y = o, G_35.position.z = s, G_35.rotation.x = l, G_35.rotation.y = c, G_35.rotation.z = h
}

function RemoveAnchor(t) {
	G_34.remove(G_35.ge("ACT_" + t))
}

function ShowAnchor(t, e) {
	G_34.ge("ACT_" + t).visible = e
}

function ShowAllAnchor(t) {
	for(var e = 0; e < G_34.children.length; e++) G_34.children[e].name.indexOf("ACT_") > -1 && (G_34.children[e].visible = t)
}

function SetBackGroundColor(t, e, n) {
	var i = "#" + ((1 << 24) + (t << 16) + (e << 8) + n).toString(16).slice(1);
	G_29 = i, G_4.sr(G_29, 1)
}

function ReSetBackGroundColor() {
	G_4.sr(G_29, 1)
}

function SaveImage() {
	render();
	var t = G_4.domElement;
	Canvas2Image.saveAsPNG(t, t.width, t.height)
}

function GetImage() {
	var t = G_4.domElement;
	return Canvas2Image.getImage(t, t.width, t.height)
}

function SetLight(t, e, n, i) {
	var r = "0x" + ((1 << 24) + (t << 16) + (e << 8) + n).toString(16).slice(1);
	G_30.color.setHex(r), G_31.color.setHex(r), G_30.intensity = 2 * i, G_31.intensity = 2 * i
}

function ResetLight() {
	G_30.color.setHex(16777215), G_31.color.setHex(16777215), G_30.intensity = 2, G_31.intensity = 2
}

function GetTypeById(t) {
	var e = new Array;
	e = t.toString().split("_");
	for(var n = 0; n < G_10.length; n++)
		if(G_10[n] == e[0]) return G_9[n][e[1]] ? G_9[n][e[1]].type : -1
}

function SetTypeColor(t, e, n, i) {
	for(var r = [], a = 0; a < G_8[0].length; a++) G_8[0][a].type == t && r.push(G_8[0][a]);
	G_14.push([e, n, i, 255]);
	for(a = 0; a < G_14.length; a++) G_18.fillStyle = "rgba(" + G_14[a][0] + "," + G_14[a][1] + "," + G_14[a][2] + ",1.0)", G_18.fillRect(a, 127, 1, 1);
	for(var o = 1 / 256 + (G_14.length - 1) / 128, a = 0; a < r.length; a++) {
		for(var s = G_3.ge(r[a].model), l = s.geometry.attributes.uv.array, c = 0; c < l.length / 2; c++) l[2 * c] = o, l[2 * c + 1] = 1 / 256;
		s.geometry.attributes.uv.needsUpdate = !0, s.material.map.needsUpdate = !0
	}
}

function SetModelPosition(t, e, n, i) {
	for(var r = -1, a = 0; a < G_10.length; a++) {
		if(G_10[a] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			GLE.Mesh
		});
		if(G_10[a] == t) {
			r = a;
			break
		}
	}
	if(!(r < 0))
		for(var o = G_8[r], a = 0; a < o.length; a++)
			if(G_3.ge(o[a].model) && ((s = G_3.ge(o[a].model)).position.z -= 1e3), G_3.ge(o[a].model.replace("big/", "small/"))) {
				var s = G_3.ge(o[a].model.replace("big/", "small/"));
				s.position.z -= 1e3
			}
}

function SetModelRotation(t, e, n, i) {
	for(var r = -1, a = 0; a < G_10.length; a++) {
		if(G_10[a] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			GLE.Mesh
		});
		if(G_10[a] == t) {
			r = a;
			break
		}
	}
	if(!(r < 0))
		for(var o = G_8[r], a = 0; a < o.length; a++)
			if(G_3.ge(o[a].model) && ((s = G_3.ge(o[a].model)).rotation.z -= .2), G_3.ge(o[a].model.replace("big/", "small/"))) {
				var s = G_3.ge(o[a].model.replace("big/", "small/"));
				s.rotation.z -= .2
			}
}

function SetModelScale(t, e, n, i) {
	for(var r = -1, a = 0; a < G_10.length; a++) {
		if(G_10[a] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			GLE.Mesh
		});
		if(G_10[a] == t) {
			r = a;
			break
		}
	}
	if(!(r < 0))
		for(var o = G_8[r], a = 0; a < o.length; a++)
			if(G_3.ge(o[a].model) && ((s = G_3.ge(o[a].model)).scale.z *= 1.2), G_3.ge(o[a].model.replace("big/", "small/"))) {
				var s = G_3.ge(o[a].model.replace("big/", "small/"));
				s.scale.z *= 1.2
			}
}

function SetModelAlpha(t, e) {
	for(var n = -1, i = 0; i < G_10.length; i++) {
		if(G_10[i] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			t instanceof GLE.Mesh && (t.material.opacity = e, t.material.transparent = !0)
		});
		if(G_10[i] == t) {
			n = i;
			break
		}
	}
	if(!(n < 0))
		for(var r = G_8[n], i = 0; i < r.length; i++)
			if(G_3.ge(r[i].model) && ((a = G_3.ge(r[i].model)).material.opacity = e), G_3.ge(r[i].model.replace("big/", "small/"))) {
				var a = G_3.ge(r[i].model.replace("big/", "small/"));
				a.material.opacity = e
			}
}

function SetModelColor(t, e, n, i) {
	for(var r = -1, a = 0; a < G_10.length; a++) {
		if(G_10[a] == "GLB_" + t) return void G_34.ge("GLB_" + t).traverse(function(t) {
			if(t instanceof GLE.Mesh) {
				t.material = new GLE.Mal;
				var r = "0x" + ((1 << 24) + (e << 16) + (n << 8) + i).toString(16).slice(1);
				t.material.color.setHex(r), 0 == e && 0 == n && 0 == i && t.material.color.setHex("0xffffff")
			}
		});
		if(G_10[a] == t) {
			r = a;
			break
		}
	}
	if(!(r < 0)) {
		for(var o = 0, a = 0; a < G_10.length; a++) G_10[a] == t && (o = a);
		for(var s = G_8[r], a = 0; a < s.length; a++) {
			if(G_3.ge(s[a].model)) {
				var l = G_3.ge(s[a].model),
					c = "0x" + ((1 << 24) + (e << 16) + (n << 8) + i).toString(16).slice(1);
				l.material.color.setHex(c), 0 == e && 0 == n && 0 == i && (l.material = G_11[o], l.material.color.setHex("0xffffff"))
			}
			if(G_3.ge(s[a].model.replace("big/", "small/"))) {
				var l = G_3.ge(s[a].model.replace("big/", "small/")),
					c = "0x" + ((1 << 24) + (e << 16) + (n << 8) + i).toString(16).slice(1);
				l.material.color.setHex(c)
			}
		}
	}
}

function SetModelVisible(t, e) {
	for(var n = -1, i = 0; i < G_10.length; i++) {
		if(G_10[i] == "GLB_" + t) {
			var r = G_34.ge("GLB_" + t);
			return r.visible = e, void r.traverse(function(t) {
				t instanceof GLE.Mesh && (t.visible = e)
			})
		}
		if(G_10[i] == t) {
			n = i;
			break
		}
	}
	if(!(n < 0))
		for(var a = G_8[n], i = 0; i < a.length; i++) {
			if(G_3.ge(a[i].model)) {
				var o = G_3.ge(a[i].model);
				"454" != a[i].type && (o.visible = e)
			}
			G_3.ge(a[i].model.replace("big/", "small/")) && ((o = G_3.ge(a[i].model.replace("big/", "small/"))).visible = e)
		}
}

function ResetClip() {
	var t = Object.freeze([]);
	G_4.cs = t, G_24 = !1
}

function PlateClip(t, e) {
	"x-min" == t && (G_41 = e), "y-min" == t && (G_42 = e), "z-min" == t && (G_43 = e), G_41 < .001 ? G_41 = -.5 : G_41 > .999 && (G_41 = 1.15), G_42 < .001 ? G_42 = -.5 : G_42 > .999 ? G_42 = 1.05 : G_42 -= .1, G_43 < .001 ? G_43 = -.7 : G_43 > .999 ? G_43 = 1.05 : G_43 -= .05;
	var n = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z) * Math.cos(G_35.rotation.x), Math.sin(G_35.rotation.z) * Math.sin(G_35.rotation.x));
	(G_38 = new GLE.Plane(n, -G_36.position.x - 1 * (G_53.min.x + G_41 * (G_53.max.x - G_53.min.x)))).translate(G_35.position);
	var i = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z), 0),
		r = new GLE.Vector3(0, 0, 1),
		a = Math.PI / 2;
	i.applyAxisAngle(r, a), i = new GLE.Vector3(i.x, i.y * Math.cos(G_35.rotation.x), i.y * Math.sin(G_35.rotation.x)), (G_39 = new GLE.Plane(i, -G_36.position.y - 1 * (G_53.min.y + G_42 * (G_53.max.y - G_53.min.y)))).translate(G_35.position);
	var o = new GLE.Vector3(0, Math.sin(-G_35.rotation.x), Math.cos(-G_35.rotation.x));
	new GLE.Vector3(0, -1, 0), Math.PI;
	(G_40 = new GLE.Plane(o, -G_36.position.z - 1 * (G_53.min.z + G_43 * (G_53.max.z - G_53.min.z)))).translate(G_35.position), zplane = new GLE.pr(new GLE.Plane(o, -1 * (G_53.min.z + G_43 * (G_53.max.z - G_53.min.z))), 3e4, 16711680);
	var s = [G_38, G_39, G_40];
	G_4.cs = s, G_24 = !0
}

function GoBackState(t) {
	var e = new Array;
	e = t.toString().split("_");
	for(var n = 0, i = -1, r = -1, a = G_44.length - 1; a > -1; a--)
		if(G_44[a][0] == e[0] && G_44[a][1] == e[1] && (1 == ++n && (i = a), 2 == n)) {
			r = a;
			break
		}
	if(0 != n && (1 == n && ResetActor(t), n > 1)) {
		G_44.splice(i, 1);
		var o = G_44[r];
		G_44.splice(r, 1), 1 == o[2] ? SetActorColor(o[0] + "_" + o[1], o[3], o[4], o[5]) : 2 == o[2] ? SetActorAlpha(o[0] + "_" + o[1], o[3]) : 3 == o[2] && SetActorVisible(o[0] + "_" + o[1], !1)
	}
}

function ResetActor(t) {
	G_19 = !0;
	var e = new Array;
	e = t.toString().split("_");
	for(i = G_44.length - 1; i > -1; i--) G_44[i][0] == e[0] && G_44[i][1] == e[1] && G_44.splice(i, 1);
	for(var n = 0, i = 0; i < G_10.length; i++) G_10[i] == e[0] && (n = i);
	var r = GetTypeById(t);
	if(-1 == r) return -1;
	for(var a = [], i = 0; i < G_8[n].length; i++) {
		for(var o = 0, s = 0; s < G_54[n][G_8[n][i].name].ids.length; s++)
			if(G_54[n][G_8[n][i].name].ids[s].id == e[1]) {
				o++;
				break
			}
		o > 0 && G_8[n][i].type == r && a.push(G_8[n][i])
	}
	for(var l = "", c = 0; c < a.length; c++) {
		l = "", m1 = a[c].model;
		for(var h = m1.split("/"), i = 0; i < h.length - 1; i++) l += h[i] + "/";
		l += h[h.length - 2] + ".info"
	}
	for(c = 0; c < a.length; c++) {
		m1 = a[c].model;
		for(var u = G_3.ge(m1), h = m1.split("/"), f = 0, i = 0; i < G_8[n].length; i++)
			if(G_8[n][i].model == m1) {
				i;
				break
			}
		for(i = 0; i < G_8[n].length; i++) G_8[n][i].model.indexOf("/" + h[h.length - 2] + "/") > 0 && f++;
		var p = [];
		p.push(e[1]);
		var d = parseInt(h[h.length - 1].replace(".glb", "").replace(h[h.length - 2], "")),
			m = 65535 * d,
			g = 65535 * d;
		g = 65535 * d + u.geometry.attributes.position.count - 1;
		for(i = 0; i < p.length; i++)
			for(var v = G_92[n][p[i]], s = 0; s < v.indices.length; s++) {
				var _ = parseInt(v.indices[s].start),
					y = parseInt(v.indices[s].end);
				if(!(_ > g || y < m)) {
					var x = m,
						b = g;
					_ > m - 1 && (x = _), y < g + 1 && (b = y);
					for(var w = x - 65535 * d; w < b + 1 - 65535 * d; w++) {
						u.geometry.attributes.uv.array[2 * w] = parseFloat(v.indices[s].type_u), u.geometry.attributes.uv.array[2 * w + 1] = parseFloat(v.indices[s].type_v);
						var M = u.geometry.attributes.position.array;
						3 == G_9[n][e[1]].status && (M[3 * w] *= 1e6, M[3 * w + 1] *= 1e6, M[3 * w + 2] *= 1e6)
					}
				}
			}
		u.geometry.attributes.uv.needsUpdate = !0, u.geometry.attributes.position.needsUpdate = !0, u.material.map.needsUpdate = !0;
		for(var S = 0; S < G_10.length; S++)
			for(i = 0; i < G_8[S].length; i++) {
				if("351" == G_8[S][i].type) {
					G = G_8[S][i].model;
					(E = G_3.ge(G)).renderOrder = 4
				}
				if("667" == G_8[S][i].type) {
					var G = G_8[S][i].model,
						E = G_3.ge(G);
					E.renderOrder = 3
				}
			}
	}
	G_9[n][e[1]].status = 0, G_19 = !1
}

function ResetAllActor() {
	for(var t = 0; t < G_10.length; t++) SetModelVisible(G_10[t], !0);
	for(var e = [], n = G_44.length - 1; n > -1; n--) {
		for(var i = 0, r = 0; r < e.length; r++)
			if(G_44[n][0] == e[r][0] && G_44[n][1] == e[r][1]) {
				i++, myindex = n;
				break
			}
		0 == i && e.push(G_44[n])
	}
	for(n = 0; n < e.length; n++) ResetActor(e[n][0] + "_" + e[n][1]);
	G_44 = []
}

function GetCamera() {
	return G_35.position.x + "," + G_35.position.y + "," + G_35.position.z + "," + G_35.rotation.x + "," + G_35.rotation.y + "," + G_35.rotation.z
}

function SetCamera(t) {
	var e = new Array;
	e = t.toString().split(","), G_35.position.x = parseFloat(e[0]), G_35.position.y = parseFloat(e[1]), G_35.position.z = parseFloat(e[2]), G_35.rotation.x = parseFloat(e[3]), G_35.rotation.y = parseFloat(e[4]), G_35.rotation.z = parseFloat(e[5])
}

function ZoomTo(t) {
	var e = new Array;
	if((e = t.split(",")).length > 1) {
		var n = parseFloat(e[0]),
			i = parseFloat(e[1]),
			r = parseFloat(e[2]),
			a = (parseFloat(e[3]), parseFloat(e[4]), parseFloat(e[5]), parseFloat(e[6])),
			o = parseFloat(e[7]),
			s = parseFloat(e[8]);
		new TN.Tn(G_35.position).to({
			x: n - a,
			y: i - o - .5 * G_32,
			z: r - s
		}, 500).easing(TN.Easing.Linear.None).start()
	} else {
		var l = t,
			c = new Array;
		c = l.toString().split("_");
		for(var h = 0, u = 0; u < G_10.length; u++) G_10[u] == c[0] && (h = u);
		var f = GetTypeById(l);
		if(-1 == f) return -1;
		for(var p = [], u = 0; u < G_8[h].length; u++) {
			for(var d = 0, m = 0; m < G_54[h][G_8[h][u].name].ids.length; m++)
				if(G_54[h][G_8[h][u].name].ids[m].id == c[1]) {
					d++;
					break
				}
			d > 0 && G_8[h][u].type == f && p.push(G_8[h][u])
		}
		var g = document.getElementById(c[0] + "-canvas");
		G_18 = g.getContext("2d");
		for(var v = "", _ = 0; _ < p.length; _++) {
			v = "", m1 = p[_].model;
			for(var y = m1.split("/"), u = 0; u < y.length - 1; u++) v += y[u] + "/";
			v += y[y.length - 2] + ".info"
		}
		for(_ = 0; _ < p.length; _++) {
			m1 = p[_].model;
			for(var x = G_3.ge(m1), y = m1.split("/"), b = 0, u = 0; u < G_8[h].length; u++)
				if(G_8[h][u].model == m1) {
					u;
					break
				}
			for(u = 0; u < G_8[h].length; u++) G_8[h][u].model.indexOf("/" + y[y.length - 2] + "/") > 0 && b++;
			var w = [];
			w.push(c[1]);
			var M = parseInt(y[y.length - 1].replace(".glb", "").replace(y[y.length - 2], ""));
			65535 * M + x.geometry.attributes.position.count - 1, ZoomFitAll();
			for(u = 0; u < w.length; u++) {
				var S = G_92[h][w[u]],
					G = S.box_0 + S.box_3 / 2,
					E = S.box_1 + S.box_4 / 2,
					T = S.box_2 + S.box_5 / 2,
					A = G_53.getCenter();
				new TN.Tn(G_35.position).to({
					x: -G + A.x,
					y: -E + A.y - .25 * G_32,
					z: -T + A.z
				}, 500).easing(TN.Easing.Linear.None).start(), new TN.Tn(G_35.rotation).to({
					x: 0,
					y: 0,
					z: 0
				}, 500).easing(TN.Easing.Linear.None).start()
			}
			x.geometry.attributes.position.needsUpdate = !0
		}
	}
}

function GetBigModel(t) {}

function SwitchBlowMode() {
	if(G_25 = !G_25) {
		G_27 = 2;
		for(a = 0; a < G_8.length; a++)
			for(var t = G_10[a], e = 0; e < G_8[a].length; e++)
				for(var n = G_8[a][e].ids, i = 0; i < n.length; i++) {
					var r = n[i].id;
					ChangeBlow(t + "_" + r, G_27)
				}
	} else {
		for(var a = 0; a < G_8.length; a++)
			for(var t = G_10[a], e = 0; e < G_8[a].length; e++)
				for(var n = G_8[a][e].ids, i = 0; i < n.length; i++) ChangeBlow(t + "_" + (r = n[i].id), -G_27);
		G_27 = 0
	}
}

function BlowIn() {
	if(G_27 < .001) G_27 = 0;
	else {
		G_27 -= .05;
		for(var t = 0; t < G_8.length; t++)
			for(var e = G_10[t], n = 0; n < G_8[t].length; n++)
				for(var i = G_8[t][n].ids, r = 0; r < i.length; r++) ChangeBlow(e + "_" + i[r].id, -.05)
	}
}

function BlowOut() {
	if(G_27 > 1.99) G_27 = 2;
	else {
		G_27 += .05;
		for(var t = 0; t < G_8.length; t++)
			for(var e = G_10[t], n = 0; n < G_8[t].length; n++)
				for(var i = G_8[t][n].ids, r = 0; r < i.length; r++) ChangeBlow(e + "_" + i[r].id, .05)
	}
}

function ChangeBlow(t, e) {
	var n = new Array;
	n = t.toString().split("_");
	for(var i = 0, r = 0; r < G_10.length; r++) G_10[r] == n[0] && (i = r);
	var a = GetTypeById(t);
	if(-1 == a) return -1;
	for(var o = [], r = 0; r < G_8[i].length; r++) {
		for(var s = 0, l = 0; l < G_54[i][G_8[i][r].name].ids.length; l++)
			if(G_54[i][G_8[i][r].name].ids[l].id == n[1]) {
				s++;
				break
			}
		s > 0 && G_8[i][r].type == a && o.push(G_8[i][r])
	}
	var c = document.getElementById(n[0] + "-canvas");
	G_18 = c.getContext("2d");
	for(var h = "", u = 0; u < o.length; u++) {
		h = "", m1 = o[u].model;
		for(var f = m1.split("/"), r = 0; r < f.length - 1; r++) h += f[r] + "/";
		h += f[f.length - 2] + ".info"
	}
	for(u = 0; u < o.length; u++) {
		m1 = o[u].model;
		for(var p = G_3.ge(m1), f = m1.split("/"), d = 0, r = 0; r < G_8[i].length; r++)
			if(G_8[i][r].model == m1) {
				r;
				break
			}
		for(r = 0; r < G_8[i].length; r++) G_8[i][r].model.indexOf("/" + f[f.length - 2] + "/") > 0 && d++;
		var m = [];
		m.push(n[1]);
		var g = parseInt(f[f.length - 1].replace(".glb", "").replace(f[f.length - 2], "")),
			v = 65535 * g,
			_ = 65535 * g;
		_ = 65535 * g + p.geometry.attributes.position.count - 1;
		for(r = 0; r < m.length; r++)
			for(var y = G_92[i][m[r]], x = y.box_0 + y.box_3 / 2, b = y.box_1 + y.box_4 / 2, w = y.box_2 + y.box_5 / 2, l = 0; l < y.indices.length; l++) {
				var M = parseInt(y.indices[l].start),
					S = parseInt(y.indices[l].end);
				if(!(M > _ || S < v)) {
					var G = v,
						E = _;
					M > v - 1 && (G = M), S < _ + 1 && (E = S);
					for(var T = G - 65535 * g; T < E + 1 - 65535 * g; T++) {
						var A = p.geometry.attributes.position.array;
						A[3 * T] += x * e, A[3 * T + 1] += b * e, A[3 * T + 2] += w * e
					}
				}
			}
		p.geometry.attributes.position.needsUpdate = !0
	}
}

function SetZoomSpeed(t) {
	G_5.zd = t
}

function SetRotateSpeed(t) {
	G_5.rd = t
}

function SetPanSpeed(t) {
	G_5.pd = t
}

function DisableUpDown() {
	G_26 = !1
}

function EnableUpDown() {
	G_26 = !0
}

function ShowActors(t) {
	for(var e = [], n = [], i = 0; i < t.length; i++) n.push(GetTypeById(t[i]));
	for(var r = 0; r < G_10.length; r++)
		for(var a = G_8[r], i = 0; i < a.length; i++)
			if(G_3.ge(a[i].model)) {
				var o = G_3.ge(a[i].model);
				if("454" != a[i].type) {
					for(var s = 0, l = 0; l < G_54[r][a[i].name].ids.length; l++) {
						for(var c = 0; c < t.length; c++) {
							var h = new Array;
							if(h = t[c].toString().split("_"), G_54[r][a[i].name].ids[l].id == h[1]) {
								s++;
								break
							}
						}
						if(s > 0) break
					}
					if(s > 0) {
						o.visible = !0;
						for(l = 0; l < G_54[r][a[i].name].ids.length; l++) e.push(G_10[r] + "_" + G_54[r][a[i].name].ids[l].id)
					} else o.visible = !1
				}
			}
	for(i = 0; i < e.length; i++) {
		for(var s = 0, l = 0; l < t.length; l++)
			if(e[i] == t[l]) {
				s++;
				break
			}
		0 == s && SetActorVisible(e[i], !1)
	}
}

function FlyAnimation(t, e) {
	for(var n = 0; n < t.length; n++) {
		var i = new Array;
		i = t[n].toString().split(",");
		var r = parseFloat(i[0]),
			a = parseFloat(i[1]),
			o = parseFloat(i[2]),
			s = parseFloat(i[3]),
			l = parseFloat(i[4]),
			c = parseFloat(i[5]);
		if(n > 0) {
			var h = new Array;
			h = t[n - 1].toString().split(",");
			var u = parseFloat(h[0]),
				f = parseFloat(h[1]),
				p = parseFloat(h[2]),
				d = parseFloat(h[3]),
				m = parseFloat(h[4]),
				g = parseFloat(h[5]);
			G_35.position.x = u, G_35.position.y = f, G_35.position.z = p, G_35.rotation.x = d, G_35.rotation.y = m, G_35.rotation.z = g, new TN.Tn(G_35.position).to({
				x: r,
				y: a,
				z: o
			}, e / (t.length - 1)).delay((n - 1) * e / t.length).easing(TN.Easing.Linear.None).start(), new TN.Tn(G_35.rotation).to({
				x: s,
				y: l,
				z: c
			}, e / (t.length - 1)).delay((n - 1) * e / t.length).easing(TN.Easing.Linear.None).start()
		} else new TN.Tn(G_35.position).to({
			x: r,
			y: a,
			z: o
		}, 1).easing(TN.Easing.Linear.None).start(), new TN.Tn(G_35.rotation).to({
			x: s,
			y: l,
			z: c
		}, 1).easing(TN.Easing.Linear.None).start()
	}
}

function SetClickMode(t) {
	G_49 = t, ClearMeasure()
}

function SetThickness(t) {
	G_52 = t
}

function assign(t, e) {
	for(var n = Object.keys(e), i = n.length, r = 0; r < i; r += 1) t[n[r]] = e[n[r]];
	return t
}

function des(t, e, n, i, r) {
	var a, o, s, l, c, h, u, f, p, d, m, g, v, _, y = new Array(16843776, 0, 65536, 16843780, 16842756, 66564, 4, 65536, 1024, 16843776, 16843780, 1024, 16778244, 16842756, 16777216, 4, 1028, 16778240, 16778240, 66560, 66560, 16842752, 16842752, 16778244, 65540, 16777220, 16777220, 65540, 0, 1028, 66564, 16777216, 65536, 16843780, 4, 16842752, 16843776, 16777216, 16777216, 1024, 16842756, 65536, 66560, 16777220, 1024, 4, 16778244, 66564, 16843780, 65540, 16842752, 16778244, 16777220, 1028, 66564, 16843776, 1028, 16778240, 16778240, 0, 65540, 66560, 0, 16842756),
		x = new Array(-2146402272, -2147450880, 32768, 1081376, 1048576, 32, -2146435040, -2147450848, -2147483616, -2146402272, -2146402304, -2147483648, -2147450880, 1048576, 32, -2146435040, 1081344, 1048608, -2147450848, 0, -2147483648, 32768, 1081376, -2146435072, 1048608, -2147483616, 0, 1081344, 32800, -2146402304, -2146435072, 32800, 0, 1081376, -2146435040, 1048576, -2147450848, -2146435072, -2146402304, 32768, -2146435072, -2147450880, 32, -2146402272, 1081376, 32, 32768, -2147483648, 32800, -2146402304, 1048576, -2147483616, 1048608, -2147450848, -2147483616, 1048608, 1081344, 0, -2147450880, 32800, -2147483648, -2146435040, -2146402272, 1081344),
		b = new Array(520, 134349312, 0, 134348808, 134218240, 0, 131592, 134218240, 131080, 134217736, 134217736, 131072, 134349320, 131080, 134348800, 520, 134217728, 8, 134349312, 512, 131584, 134348800, 134348808, 131592, 134218248, 131584, 131072, 134218248, 8, 134349320, 512, 134217728, 134349312, 134217728, 131080, 520, 131072, 134349312, 134218240, 0, 512, 131080, 134349320, 134218240, 134217736, 512, 0, 134348808, 134218248, 131072, 134217728, 134349320, 8, 131592, 131584, 134217736, 134348800, 134218248, 520, 134348800, 131592, 8, 134348808, 131584),
		w = new Array(8396801, 8321, 8321, 128, 8396928, 8388737, 8388609, 8193, 0, 8396800, 8396800, 8396929, 129, 0, 8388736, 8388609, 1, 8192, 8388608, 8396801, 128, 8388608, 8193, 8320, 8388737, 1, 8320, 8388736, 8192, 8396928, 8396929, 129, 8388736, 8388609, 8396800, 8396929, 129, 0, 0, 8396800, 8320, 8388736, 8388737, 1, 8396801, 8321, 8321, 128, 8396929, 129, 1, 8192, 8388609, 8193, 8396928, 8388737, 8193, 8320, 8388608, 8396801, 128, 8388608, 8192, 8396928),
		M = new Array(256, 34078976, 34078720, 1107296512, 524288, 256, 1073741824, 34078720, 1074266368, 524288, 33554688, 1074266368, 1107296512, 1107820544, 524544, 1073741824, 33554432, 1074266112, 1074266112, 0, 1073742080, 1107820800, 1107820800, 33554688, 1107820544, 1073742080, 0, 1107296256, 34078976, 33554432, 1107296256, 524544, 524288, 1107296512, 256, 33554432, 1073741824, 34078720, 1107296512, 1074266368, 33554688, 1073741824, 1107820544, 34078976, 1074266368, 256, 33554432, 1107820544, 1107820800, 524544, 1107296256, 1107820800, 34078720, 0, 1074266112, 1107296256, 524544, 33554688, 1073742080, 524288, 0, 1074266112, 34078976, 1073742080),
		S = new Array(536870928, 541065216, 16384, 541081616, 541065216, 16, 541081616, 4194304, 536887296, 4210704, 4194304, 536870928, 4194320, 536887296, 536870912, 16400, 0, 4194320, 536887312, 16384, 4210688, 536887312, 16, 541065232, 541065232, 0, 4210704, 541081600, 16400, 4210688, 541081600, 536870912, 536887296, 16, 541065232, 4210688, 541081616, 4194304, 16400, 536870928, 4194304, 536887296, 536870912, 16400, 536870928, 541081616, 4210688, 541065216, 4210704, 541081600, 0, 541065232, 16, 16384, 541065216, 4210704, 16384, 4194320, 536887312, 0, 541081600, 536870912, 4194320, 536887312),
		G = new Array(2097152, 69206018, 67110914, 0, 2048, 67110914, 2099202, 69208064, 69208066, 2097152, 0, 67108866, 2, 67108864, 69206018, 2050, 67110912, 2099202, 2097154, 67110912, 67108866, 69206016, 69208064, 2097154, 69206016, 2048, 2050, 69208066, 2099200, 2, 67108864, 2099200, 67108864, 2099200, 2097152, 67110914, 67110914, 69206018, 69206018, 2, 2097154, 67108864, 67110912, 2097152, 69208064, 2050, 2099202, 69208064, 2050, 67108866, 69208066, 69206016, 2099200, 0, 2, 69208066, 0, 2099202, 69206016, 2048, 67108866, 67110912, 2048, 2097154),
		E = new Array(268439616, 4096, 262144, 268701760, 268435456, 268439616, 64, 268435456, 262208, 268697600, 268701760, 266240, 268701696, 266304, 4096, 64, 268697600, 268435520, 268439552, 4160, 266240, 262208, 268697664, 268701696, 4160, 0, 0, 268697664, 268435520, 268439552, 266304, 262144, 266304, 262144, 268701696, 4096, 64, 268697664, 4096, 266304, 268439552, 64, 268435520, 268697600, 268697664, 268435456, 262144, 268439616, 0, 268701760, 262208, 268435520, 268697600, 268439552, 268439616, 0, 268701760, 266240, 266240, 4160, 4160, 262208, 268435456, 268701696),
		T = des_createKeys(t),
		A = 0,
		L = e.length,
		C = 0,
		P = 32 == T.length ? 3 : 9;
	for(f = 3 == P ? n ? new Array(0, 32, 2) : new Array(30, -2, -2) : n ? new Array(0, 32, 2, 62, 30, -2, 64, 96, 2) : new Array(94, 62, -2, 32, 64, 2, 30, -2, -2), e += "\0\0\0\0\0\0\0\0", result = "", tempresult = "", 1 == i && (p = r.charCodeAt(A++) << 24 | r.charCodeAt(A++) << 16 | r.charCodeAt(A++) << 8 | r.charCodeAt(A++), m = r.charCodeAt(A++) << 24 | r.charCodeAt(A++) << 16 | r.charCodeAt(A++) << 8 | r.charCodeAt(A++), A = 0); A < L;) {
		for(n ? (h = e.charCodeAt(A++) << 16 | e.charCodeAt(A++), u = e.charCodeAt(A++) << 16 | e.charCodeAt(A++)) : (h = e.charCodeAt(A++) << 24 | e.charCodeAt(A++) << 16 | e.charCodeAt(A++) << 8 | e.charCodeAt(A++), u = e.charCodeAt(A++) << 24 | e.charCodeAt(A++) << 16 | e.charCodeAt(A++) << 8 | e.charCodeAt(A++)), 1 == i && (n ? (h ^= p, u ^= m) : (d = p, g = m, p = h, m = u)), h ^= (s = 252645135 & (h >>> 4 ^ u)) << 4, h ^= (s = 65535 & (h >>> 16 ^ (u ^= s))) << 16, h ^= s = 858993459 & ((u ^= s) >>> 2 ^ h), h ^= s = 16711935 & ((u ^= s << 2) >>> 8 ^ h), h = (h ^= (s = 1431655765 & (h >>> 1 ^ (u ^= s << 8))) << 1) << 1 | h >>> 31, u = (u ^= s) << 1 | u >>> 31, o = 0; o < P; o += 3) {
			for(v = f[o + 1], _ = f[o + 2], a = f[o]; a != v; a += _) l = u ^ T[a], c = (u >>> 4 | u << 28) ^ T[a + 1], s = h, h = u, u = s ^ (x[l >>> 24 & 63] | w[l >>> 16 & 63] | S[l >>> 8 & 63] | E[63 & l] | y[c >>> 24 & 63] | b[c >>> 16 & 63] | M[c >>> 8 & 63] | G[63 & c]);
			s = h, h = u, u = s
		}
		u = u >>> 1 | u << 31, u ^= s = 1431655765 & ((h = h >>> 1 | h << 31) >>> 1 ^ u), u ^= (s = 16711935 & (u >>> 8 ^ (h ^= s << 1))) << 8, u ^= (s = 858993459 & (u >>> 2 ^ (h ^= s))) << 2, u ^= s = 65535 & ((h ^= s) >>> 16 ^ u), u ^= s = 252645135 & ((h ^= s << 16) >>> 4 ^ u), h ^= s << 4, 1 == i && (n ? (p = h, m = u) : (h ^= d, u ^= g)), tempresult += n ? String.fromCharCode(h >>> 24, h >>> 16 & 255, h >>> 8 & 255, 255 & h, u >>> 24, u >>> 16 & 255, u >>> 8 & 255, 255 & u) : String.fromCharCode(h >>> 16 & 65535, 65535 & h, u >>> 16 & 65535, 65535 & u), 512 == (C += n ? 16 : 8) && (result += tempresult, tempresult = "", C = 0)
	}
	return result + tempresult
}

function des_createKeys(t) {
	pc2bytes0 = new Array(0, 4, 536870912, 536870916, 65536, 65540, 536936448, 536936452, 512, 516, 536871424, 536871428, 66048, 66052, 536936960, 536936964), pc2bytes1 = new Array(0, 1, 1048576, 1048577, 67108864, 67108865, 68157440, 68157441, 256, 257, 1048832, 1048833, 67109120, 67109121, 68157696, 68157697), pc2bytes2 = new Array(0, 8, 2048, 2056, 16777216, 16777224, 16779264, 16779272, 0, 8, 2048, 2056, 16777216, 16777224, 16779264, 16779272), pc2bytes3 = new Array(0, 2097152, 134217728, 136314880, 8192, 2105344, 134225920, 136323072, 131072, 2228224, 134348800, 136445952, 139264, 2236416, 134356992, 136454144), pc2bytes4 = new Array(0, 262144, 16, 262160, 0, 262144, 16, 262160, 4096, 266240, 4112, 266256, 4096, 266240, 4112, 266256), pc2bytes5 = new Array(0, 1024, 32, 1056, 0, 1024, 32, 1056, 33554432, 33555456, 33554464, 33555488, 33554432, 33555456, 33554464, 33555488), pc2bytes6 = new Array(0, 268435456, 524288, 268959744, 2, 268435458, 524290, 268959746, 0, 268435456, 524288, 268959744, 2, 268435458, 524290, 268959746), pc2bytes7 = new Array(0, 65536, 2048, 67584, 536870912, 536936448, 536872960, 536938496, 131072, 196608, 133120, 198656, 537001984, 537067520, 537004032, 537069568), pc2bytes8 = new Array(0, 262144, 0, 262144, 2, 262146, 2, 262146, 33554432, 33816576, 33554432, 33816576, 33554434, 33816578, 33554434, 33816578), pc2bytes9 = new Array(0, 268435456, 8, 268435464, 0, 268435456, 8, 268435464, 1024, 268436480, 1032, 268436488, 1024, 268436480, 1032, 268436488), pc2bytes10 = new Array(0, 32, 0, 32, 1048576, 1048608, 1048576, 1048608, 8192, 8224, 8192, 8224, 1056768, 1056800, 1056768, 1056800), pc2bytes11 = new Array(0, 16777216, 512, 16777728, 2097152, 18874368, 2097664, 18874880, 67108864, 83886080, 67109376, 83886592, 69206016, 85983232, 69206528, 85983744), pc2bytes12 = new Array(0, 4096, 134217728, 134221824, 524288, 528384, 134742016, 134746112, 16, 4112, 134217744, 134221840, 524304, 528400, 134742032, 134746128), pc2bytes13 = new Array(0, 4, 256, 260, 0, 4, 256, 260, 1, 5, 257, 261, 1, 5, 257, 261);
	for(var e, n, r, a = t.length >= 24 ? 3 : 1, o = new Array(32 * a), s = new Array(0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0), l = 0, c = 0, h = 0; h < a; h++)
		for(left = t.charCodeAt(l++) << 24 | t.charCodeAt(l++) << 16 | t.charCodeAt(l++) << 8 | t.charCodeAt(l++), right = t.charCodeAt(l++) << 24 | t.charCodeAt(l++) << 16 | t.charCodeAt(l++) << 8 | t.charCodeAt(l++), r = 252645135 & (left >>> 4 ^ right), right ^= r, left ^= r << 4, r = 65535 & (right >>> -16 ^ left), left ^= r, right ^= r << -16, r = 858993459 & (left >>> 2 ^ right), right ^= r, left ^= r << 2, r = 65535 & (right >>> -16 ^ left), left ^= r, right ^= r << -16, r = 1431655765 & (left >>> 1 ^ right), right ^= r, left ^= r << 1, r = 16711935 & (right >>> 8 ^ left), left ^= r, right ^= r << 8, r = 1431655765 & (left >>> 1 ^ right), right ^= r, left ^= r << 1, r = left << 8 | right >>> 20 & 240, left = right << 24 | right << 8 & 16711680 | right >>> 8 & 65280 | right >>> 24 & 240, right = r, i = 0; i < s.length; i++) s[i] ? (left = left << 2 | left >>> 26, right = right << 2 | right >>> 26) : (left = left << 1 | left >>> 27, right = right << 1 | right >>> 27), left &= -15, right &= -15, e = pc2bytes0[left >>> 28] | pc2bytes1[left >>> 24 & 15] | pc2bytes2[left >>> 20 & 15] | pc2bytes3[left >>> 16 & 15] | pc2bytes4[left >>> 12 & 15] | pc2bytes5[left >>> 8 & 15] | pc2bytes6[left >>> 4 & 15], r = 65535 & ((n = pc2bytes7[right >>> 28] | pc2bytes8[right >>> 24 & 15] | pc2bytes9[right >>> 20 & 15] | pc2bytes10[right >>> 16 & 15] | pc2bytes11[right >>> 12 & 15] | pc2bytes12[right >>> 8 & 15] | pc2bytes13[right >>> 4 & 15]) >>> 16 ^ e), o[c++] = e ^ r, o[c++] = n ^ r << 16;
	return o
}

function stringToHex(t) {
	for(var e = "", n = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f"), i = 0; i < t.length; i++) e += n[t.charCodeAt(i) >> 4] + n[15 & t.charCodeAt(i)];
	return e
}

function HexTostring(t) {
	for(var e = "", n = 0; n < t.length; n += 2) {
		var i = parseInt(t.substring(n, n + 2), 16);
		e += String.fromCharCode(i)
	}
	return e
}

function encMe(t, e) {
	return stringToHex(des(e, t, 1, 0))
}

function uncMe(t, e) {
	return des(e, HexTostring(t), 0, 0)
}! function(t, e) {
	"object" == typeof exports && "undefined" != typeof module ? e(exports) : "function" == typeof define && define.amd ? define(["exports"], e) : e(t.GLE = {})
}(this, function(t) {
	"use strict";

	function e() {}

	function n(t, e) {
		this.x = t || 0, this.y = e || 0
	}

	function i() {
		this.elements = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], arguments.length
	}

	function r(t, e, n, i) {
		this._x = t || 0, this._y = e || 0, this._z = n || 0, this._w = void 0 !== i ? i : 1
	}

	function a(t, e, n) {
		this.x = t || 0, this.y = e || 0, this.z = n || 0
	}

	function o() {
		this.elements = [1, 0, 0, 0, 1, 0, 0, 0, 1], arguments.length
	}

	function s(t, e, i, r, a, l, c, h, u, f) {
		Object.defineProperty(this, "id", {
			value: Na++
		}), this.uuid = Oa.generateUUID(), this.name = "", this.image = void 0 !== t ? t : s.DEFAULT_IMAGE, this.mipmaps = [], this.mapping = void 0 !== e ? e : s.DEFAULT_MAPPING, this.wrapS = void 0 !== i ? i : Fr, this.wrapT = void 0 !== r ? r : Fr, this.magFilter = void 0 !== a ? a : Hr, this.minFilter = void 0 !== l ? l : Xr, this.anisotropy = void 0 !== u ? u : 1, this.format = void 0 !== c ? c : sa, this.type = void 0 !== h ? h : Yr, this.offset = new n(0, 0), this.repeat = new n(1, 1), this.center = new n(0, 0), this.rotation = 0, this.matrixAutoUpdate = !0, this.matrix = new o, this.generateMipmaps = !0, this.premultiplyAlpha = !1, this.flipY = !0, this.unpackAlignment = 4, this.encoding = void 0 !== f ? f : Ga, this.version = 0, this.onUpdate = null
	}

	function l(t, e, n, i) {
		this.x = t || 0, this.y = e || 0, this.z = n || 0, this.w = void 0 !== i ? i : 1
	}

	function c(t, e, n) {
		this.uuid = Oa.generateUUID(), this.width = t, this.height = e, this.scissor = new l(0, 0, t, e), this.scissorTest = !1, this.viewport = new l(0, 0, t, e), void 0 === (n = n || {}).minFilter && (n.minFilter = Hr), this.texture = new s(void 0, void 0, n.wrapS, n.wrapT, n.magFilter, n.minFilter, n.format, n.type, n.anisotropy, n.encoding), this.depthBuffer = void 0 === n.depthBuffer || n.depthBuffer, this.stencilBuffer = void 0 === n.stencilBuffer || n.stencilBuffer, this.depthTexture = void 0 !== n.depthTexture ? n.depthTexture : null
	}

	function h(t, e, n) {
		c.call(this, t, e, n), this.activeCubeFace = 0, this.activeMipMapLevel = 0
	}

	function u(t, e, n, i, r, a, o, l, c, h, u, f) {
		s.call(this, null, a, o, l, c, h, i, r, u, f), this.image = {
			data: t,
			width: e,
			height: n
		}, this.magFilter = void 0 !== c ? c : Br, this.minFilter = void 0 !== h ? h : Br, this.generateMipmaps = !1, this.flipY = !1, this.unpackAlignment = 1
	}

	function f(t, e, n, i, r, a, o, l, c, h) {
		t = void 0 !== t ? t : [], e = void 0 !== e ? e : Pr, s.call(this, t, e, n, i, r, a, o, l, c, h), this.flipY = !1
	}

	function p() {
		this.seq = [], this.map = {}
	}

	function d(t, e, n) {
		var i = t[0];
		if(i <= 0 || i > 0) return t;
		var r = e * n,
			a = Ua[r];
		if(void 0 === a && (a = new Float32Array(r), Ua[r] = a), 0 !== e) {
			i.toArray(a, 0);
			for(var o = 1, s = 0; o !== e; ++o) s += n, t[o].toArray(a, s)
		}
		return a
	}

	function m(t, e) {
		var n = Fa[e];
		void 0 === n && (n = new Int32Array(e), Fa[e] = n);
		for(var i = 0; i !== e; ++i) n[i] = t.allocTextureUnit();
		return n
	}

	function g(t, e) {
		t.uniform1f(this.addr, e)
	}

	function v(t, e) {
		t.uniform1i(this.addr, e)
	}

	function _(t, e) {
		void 0 === e.x ? t.uniform2fv(this.addr, e) : t.uniform2f(this.addr, e.x, e.y)
	}

	function y(t, e) {
		void 0 !== e.x ? t.uniform3f(this.addr, e.x, e.y, e.z) : void 0 !== e.r ? t.uniform3f(this.addr, e.r, e.g, e.b) : t.uniform3fv(this.addr, e)
	}

	function x(t, e) {
		void 0 === e.x ? t.uniform4fv(this.addr, e) : t.uniform4f(this.addr, e.x, e.y, e.z, e.w)
	}

	function b(t, e) {
		t.uniformMatrix2fv(this.addr, !1, e.elements || e)
	}

	function w(t, e) {
		void 0 === e.elements ? t.uniformMatrix3fv(this.addr, !1, e) : (Ba.set(e.elements), t.uniformMatrix3fv(this.addr, !1, Ba))
	}

	function M(t, e) {
		void 0 === e.elements ? t.uniformMatrix4fv(this.addr, !1, e) : (ka.set(e.elements), t.uniformMatrix4fv(this.addr, !1, ka))
	}

	function S(t, e, n) {
		var i = n.allocTextureUnit();
		t.uniform1i(this.addr, i), n.setTexture2D(e || Da, i)
	}

	function G(t, e, n) {
		var i = n.allocTextureUnit();
		t.uniform1i(this.addr, i), n.setTextureCube(e || za, i)
	}

	function E(t, e) {
		t.uniform2iv(this.addr, e)
	}

	function T(t, e) {
		t.uniform3iv(this.addr, e)
	}

	function A(t, e) {
		t.uniform4iv(this.addr, e)
	}

	function L(t) {
		switch(t) {
			case 5126:
				return g;
			case 35664:
				return _;
			case 35665:
				return y;
			case 35666:
				return x;
			case 35674:
				return b;
			case 35675:
				return w;
			case 35676:
				return M;
			case 35678:
			case 36198:
				return S;
			case 35680:
				return G;
			case 5124:
			case 35670:
				return v;
			case 35667:
			case 35671:
				return E;
			case 35668:
			case 35672:
				return T;
			case 35669:
			case 35673:
				return A
		}
	}

	function C(t, e) {
		t.uniform1fv(this.addr, e)
	}

	function P(t, e) {
		t.uniform1iv(this.addr, e)
	}

	function I(t, e) {
		t.uniform2fv(this.addr, d(e, this.size, 2))
	}

	function R(t, e) {
		t.uniform3fv(this.addr, d(e, this.size, 3))
	}

	function O(t, e) {
		t.uniform4fv(this.addr, d(e, this.size, 4))
	}

	function N(t, e) {
		t.uniformMatrix2fv(this.addr, !1, d(e, this.size, 4))
	}

	function D(t, e) {
		t.uniformMatrix3fv(this.addr, !1, d(e, this.size, 9))
	}

	function z(t, e) {
		t.uniformMatrix4fv(this.addr, !1, d(e, this.size, 16))
	}

	function U(t, e, n) {
		var i = e.length,
			r = m(n, i);
		t.uniform1iv(this.addr, r);
		for(var a = 0; a !== i; ++a) n.setTexture2D(e[a] || Da, r[a])
	}

	function F(t, e, n) {
		var i = e.length,
			r = m(n, i);
		t.uniform1iv(this.addr, r);
		for(var a = 0; a !== i; ++a) n.setTextureCube(e[a] || za, r[a])
	}

	function k(t) {
		switch(t) {
			case 5126:
				return C;
			case 35664:
				return I;
			case 35665:
				return R;
			case 35666:
				return O;
			case 35674:
				return N;
			case 35675:
				return D;
			case 35676:
				return z;
			case 35678:
				return U;
			case 35680:
				return F;
			case 5124:
			case 35670:
				return P;
			case 35667:
			case 35671:
				return E;
			case 35668:
			case 35672:
				return T;
			case 35669:
			case 35673:
				return A
		}
	}

	function B(t, e, n) {
		this.id = t, this.addr = n, this.setValue = L(e.type)
	}

	function V(t, e, n) {
		this.id = t, this.addr = n, this.size = e.size, this.setValue = k(e.type)
	}

	function j(t) {
		this.id = t, p.call(this)
	}

	function H(t, e) {
		t.seq.push(e), t.map[e.id] = e
	}

	function W(t, e, n) {
		var i = t.name,
			r = i.length;
		for(Va.lastIndex = 0;;) {
			var a = Va.exec(i),
				o = Va.lastIndex,
				s = a[1],
				l = "]" === a[2],
				c = a[3];
			if(l && (s |= 0), void 0 === c || "[" === c && o + 2 === r) {
				H(n, void 0 === c ? new B(s, t, e) : new V(s, t, e));
				break
			}
			var h = n.map[s];
			void 0 === h && H(n, h = new j(s)), n = h
		}
	}

	function X(t, e, n) {
		p.call(this), this.renderer = n;
		for(var i = t.getProgramParameter(e, t.ACTIVE_UNIFORMS), r = 0; r < i; ++r) {
			var a = t.getActiveUniform(e, r),
				o = a.name;
			W(a, t.getUniformLocation(e, o), this)
		}
	}

	function Y(t, e, n) {
		return void 0 === e && void 0 === n ? this.set(t) : this.setRGB(t, e, n)
	}

	function q(t, e) {
		this.min = void 0 !== t ? t : new n(1 / 0, 1 / 0), this.max = void 0 !== e ? e : new n(-1 / 0, -1 / 0)
	}

	function Z(t, e, i, r, o) {
		function s() {
			var t = new Float32Array([-1, -1, 0, 0, 1, -1, 1, 0, 1, 1, 1, 1, -1, 1, 0, 1]),
				n = new Uint16Array([0, 1, 2, 0, 2, 3]);
			c = e.createBuffer(), h = e.createBuffer(), e.bindBuffer(e.ARRAY_BUFFER, c), e.bufferData(e.ARRAY_BUFFER, t, e.STATIC_DRAW), e.bindBuffer(e.ELEMENT_ARRAY_BUFFER, h), e.bufferData(e.ELEMENT_ARRAY_BUFFER, n, e.STATIC_DRAW), m = e.createTexture(), g = e.createTexture(), i.bindTexture(e.TEXTURE_2D, m), e.texImage2D(e.TEXTURE_2D, 0, e.RGB, 16, 16, 0, e.RGB, e.UNSIGNED_BYTE, null), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_WRAP_S, e.CLAMP_TO_EDGE), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_WRAP_T, e.CLAMP_TO_EDGE), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_MAG_FILTER, e.NEAREST), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_MIN_FILTER, e.NEAREST), i.bindTexture(e.TEXTURE_2D, g), e.texImage2D(e.TEXTURE_2D, 0, e.RGBA, 16, 16, 0, e.RGBA, e.UNSIGNED_BYTE, null), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_WRAP_S, e.CLAMP_TO_EDGE), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_WRAP_T, e.CLAMP_TO_EDGE), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_MAG_FILTER, e.NEAREST), e.texParameteri(e.TEXTURE_2D, e.TEXTURE_MIN_FILTER, e.NEAREST), u = {
				vertexShader: ["uniform lowp int renderType;", "uniform vec3 screenPosition;", "uniform vec2 scale;", "uniform float rotation;", "uniform sampler2D occlusionMap;", "attribute vec2 position;", "attribute vec2 uv;", "varying vec2 vUV;", "varying float vVisibility;", "void main() {", "\tvUV = uv;", "\tvec2 pos = position;", "\tif ( renderType == 2 ) {", "\t\tvec4 visibility = texture2D( occlusionMap, vec2( 0.1, 0.1 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.5, 0.1 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.9, 0.1 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.9, 0.5 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.9, 0.9 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.5, 0.9 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.1, 0.9 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.1, 0.5 ) );", "\t\tvisibility += texture2D( occlusionMap, vec2( 0.5, 0.5 ) );", "\t\tvVisibility =        visibility.r / 9.0;", "\t\tvVisibility *= 1.0 - visibility.g / 9.0;", "\t\tvVisibility *=       visibility.b / 9.0;", "\t\tvVisibility *= 1.0 - visibility.a / 9.0;", "\t\tpos.x = cos( rotation ) * position.x - sin( rotation ) * position.y;", "\t\tpos.y = sin( rotation ) * position.x + cos( rotation ) * position.y;", "\t}", "\tgl_Position = vec4( ( pos * scale + screenPosition.xy ).xy, screenPosition.z, 1.0 );", "}"].join("\n"),
				fragmentShader: ["uniform lowp int renderType;", "uniform sampler2D map;", "uniform float opacity;", "uniform vec3 color;", "varying vec2 vUV;", "varying float vVisibility;", "void main() {", "\tif ( renderType == 0 ) {", "\t\tgl_FragColor = vec4( 1.0, 0.0, 1.0, 0.0 );", "\t} else if ( renderType == 1 ) {", "\t\tgl_FragColor = texture2D( map, vUV );", "\t} else {", "\t\tvec4 texture = texture2D( map, vUV );", "\t\ttexture.a *= opacity * vVisibility;", "\t\tgl_FragColor = texture;", "\t\tgl_FragColor.rgb *= color;", "\t}", "}"].join("\n")
			}, f = l(u), p = {
				vertex: e.getAttribLocation(f, "position"),
				uv: e.getAttribLocation(f, "uv")
			}, d = {
				renderType: e.getUniformLocation(f, "renderType"),
				map: e.getUniformLocation(f, "map"),
				occlusionMap: e.getUniformLocation(f, "occlusionMap"),
				opacity: e.getUniformLocation(f, "opacity"),
				color: e.getUniformLocation(f, "color"),
				scale: e.getUniformLocation(f, "scale"),
				rotation: e.getUniformLocation(f, "rotation"),
				screenPosition: e.getUniformLocation(f, "screenPosition")
			}
		}

		function l(t) {
			var n = e.createProgram(),
				i = e.createShader(e.FRAGMENT_SHADER),
				r = e.createShader(e.VERTEX_SHADER),
				a = "precision " + o.precision + " float;\n";
			return e.shaderSource(i, a + t.fragmentShader), e.shaderSource(r, a + t.vertexShader), e.compileShader(i), e.compileShader(r), e.attachShader(n, i), e.attachShader(n, r), e.linkProgram(n), n
		}
		var c, h, u, f, p, d, m, g;
		this.render = function(t, o, l, u) {
			if(0 !== t.length) {
				var v = new a,
					_ = u.w / u.z,
					y = .5 * u.z,
					x = .5 * u.w,
					b = 16 / u.w,
					w = new n(b * _, b),
					M = new a(1, 1, 0),
					S = new n(1, 1),
					G = new q;
				G.min.set(u.x, u.y), G.max.set(u.x + (u.z - 16), u.y + (u.w - 16)), void 0 === f && s(), i.useProgram(f), i.initAttributes(), i.enableAttribute(p.vertex), i.enableAttribute(p.uv), i.disableUnusedAttributes(), e.uniform1i(d.occlusionMap, 0), e.uniform1i(d.map, 1), e.bindBuffer(e.ARRAY_BUFFER, c), e.vertexAttribPointer(p.vertex, 2, e.FLOAT, !1, 16, 0), e.vertexAttribPointer(p.uv, 2, e.FLOAT, !1, 16, 8), e.bindBuffer(e.ELEMENT_ARRAY_BUFFER, h), i.disable(e.CULL_FACE), i.buffers.depth.setMask(!1);
				for(var E = 0, T = t.length; E < T; E++) {
					b = 16 / u.w, w.set(b * _, b);
					var A = t[E];
					if(v.set(A.matrixWorld.elements[12], A.matrixWorld.elements[13], A.matrixWorld.elements[14]), v.applyMatrix4(l.matrixWorldInverse), v.applyMatrix4(l.projectionMatrix), M.copy(v), S.x = u.x + M.x * y + y - 8, S.y = u.y + M.y * x + x - 8, !0 === G.containsPoint(S)) {
						i.activeTexture(e.TEXTURE0), i.bindTexture(e.TEXTURE_2D, null), i.activeTexture(e.TEXTURE1), i.bindTexture(e.TEXTURE_2D, m), e.copyTexImage2D(e.TEXTURE_2D, 0, e.RGB, S.x, S.y, 16, 16, 0), e.uniform1i(d.renderType, 0), e.uniform2f(d.scale, w.x, w.y), e.uniform3f(d.screenPosition, M.x, M.y, M.z), i.disable(e.BLEND), i.enable(e.DEPTH_TEST), e.drawElements(e.TRIANGLES, 6, e.UNSIGNED_SHORT, 0), i.activeTexture(e.TEXTURE0), i.bindTexture(e.TEXTURE_2D, g), e.copyTexImage2D(e.TEXTURE_2D, 0, e.RGBA, S.x, S.y, 16, 16, 0), e.uniform1i(d.renderType, 1), i.disable(e.DEPTH_TEST), i.activeTexture(e.TEXTURE1), i.bindTexture(e.TEXTURE_2D, m), e.drawElements(e.TRIANGLES, 6, e.UNSIGNED_SHORT, 0), A.positionScreen.copy(M), A.customUpdateCallback ? A.customUpdateCallback(A) : A.updateLensFlares(), e.uniform1i(d.renderType, 2), i.enable(e.BLEND);
						for(var L = 0, C = A.lensFlares.length; L < C; L++) {
							var P = A.lensFlares[L];
							P.opacity > .001 && P.scale > .001 && (M.x = P.x, M.y = P.y, M.z = P.z, b = P.size * P.scale / u.w, w.x = b * _, w.y = b, e.uniform3f(d.screenPosition, M.x, M.y, M.z), e.uniform2f(d.scale, w.x, w.y), e.uniform1f(d.rotation, P.rotation), e.uniform1f(d.opacity, P.opacity), e.uniform3f(d.color, P.color.r, P.color.g, P.color.b), i.setBlending(P.blending, P.blendEquation, P.blendSrc, P.blendDst), r.setTexture2D(P.texture, 1), e.drawElements(e.TRIANGLES, 6, e.UNSIGNED_SHORT, 0))
						}
					}
				}
				i.enable(e.CULL_FACE), i.enable(e.DEPTH_TEST), i.buffers.depth.setMask(!0), i.reset()
			}
		}
	}

	function J(t, e, n, i, r, a, o, l, c) {
		s.call(this, t, e, n, i, r, a, o, l, c), this.needsUpdate = !0
	}

	function K(t, e, n, i, o) {
		function s() {
			var t = new Float32Array([-.5, -.5, 0, 0, .5, -.5, 1, 0, .5, .5, 1, 1, -.5, .5, 0, 1]),
				n = new Uint16Array([0, 1, 2, 0, 2, 3]);
			h = e.createBuffer(), u = e.createBuffer(), e.bindBuffer(e.ARRAY_BUFFER, h), e.bufferData(e.ARRAY_BUFFER, t, e.STATIC_DRAW), e.bindBuffer(e.ELEMENT_ARRAY_BUFFER, u), e.bufferData(e.ELEMENT_ARRAY_BUFFER, n, e.STATIC_DRAW), f = l(), p = {
				position: e.getAttribLocation(f, "position"),
				uv: e.getAttribLocation(f, "uv")
			}, d = {
				uvOffset: e.getUniformLocation(f, "uvOffset"),
				uvScale: e.getUniformLocation(f, "uvScale"),
				rotation: e.getUniformLocation(f, "rotation"),
				scale: e.getUniformLocation(f, "scale"),
				color: e.getUniformLocation(f, "color"),
				map: e.getUniformLocation(f, "map"),
				opacity: e.getUniformLocation(f, "opacity"),
				modelViewMatrix: e.getUniformLocation(f, "modelViewMatrix"),
				projectionMatrix: e.getUniformLocation(f, "projectionMatrix"),
				fogType: e.getUniformLocation(f, "fogType"),
				fogDensity: e.getUniformLocation(f, "fogDensity"),
				fogNear: e.getUniformLocation(f, "fogNear"),
				fogFar: e.getUniformLocation(f, "fogFar"),
				fogColor: e.getUniformLocation(f, "fogColor"),
				fogDepth: e.getUniformLocation(f, "fogDepth"),
				alphaTest: e.getUniformLocation(f, "alphaTest")
			};
			var i = document.createElementNS("http://www.w3.org/1999/xhtml", "canvas");
			i.width = 8, i.height = 8;
			var r = i.getContext("2d");
			r.fillStyle = "white", r.fillRect(0, 0, 8, 8), m = new J(i)
		}

		function l() {
			var t = e.createProgram(),
				n = e.createShader(e.VERTEX_SHADER),
				i = e.createShader(e.FRAGMENT_SHADER);
			return e.shaderSource(n, ["precision " + o.precision + " float;", "#define SHADER_NAME SpriteMaterial", "uniform mat4 modelViewMatrix;", "uniform mat4 projectionMatrix;", "uniform float rotation;", "uniform vec2 scale;", "uniform vec2 uvOffset;", "uniform vec2 uvScale;", "attribute vec2 position;", "attribute vec2 uv;", "varying vec2 vUV;", "varying float fogDepth;", "void main() {", "\tvUV = uvOffset + uv * uvScale;", "\tvec2 alignedPosition = position * scale;", "\tvec2 rotatedPosition;", "\trotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;", "\trotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;", "\tvec4 mvPosition;", "\tmvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );", "\tmvPosition.xy += rotatedPosition;", "\tgl_Position = projectionMatrix * mvPosition;", "\tfogDepth = - mvPosition.z;", "}"].join("\n")), e.shaderSource(i, ["precision " + o.precision + " float;", "#define SHADER_NAME SpriteMaterial", "uniform vec3 color;", "uniform sampler2D map;", "uniform float opacity;", "uniform int fogType;", "uniform vec3 fogColor;", "uniform float fogDensity;", "uniform float fogNear;", "uniform float fogFar;", "uniform float alphaTest;", "varying vec2 vUV;", "varying float fogDepth;", "void main() {", "\tvec4 texture = texture2D( map, vUV );", "\tgl_FragColor = vec4( color * texture.xyz, texture.a * opacity );", "\tif ( gl_FragColor.a < alphaTest ) discard;", "\tif ( fogType > 0 ) {", "\t\tfloat fogFactor = 0.0;", "\t\tif ( fogType == 1 ) {", "\t\t\tfogFactor = smoothstep( fogNear, fogFar, fogDepth );", "\t\t} else {", "\t\t\tconst float LOG2 = 1.442695;", "\t\t\tfogFactor = exp2( - fogDensity * fogDensity * fogDepth * fogDepth * LOG2 );", "\t\t\tfogFactor = 1.0 - clamp( fogFactor, 0.0, 1.0 );", "\t\t}", "\t\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );", "\t}", "}"].join("\n")), e.compileShader(n), e.compileShader(i), e.attachShader(t, n), e.attachShader(t, i), e.linkProgram(t), t
		}

		function c(t, e) {
			return t.renderOrder !== e.renderOrder ? t.renderOrder - e.renderOrder : t.z !== e.z ? e.z - t.z : e.id - t.id
		}
		var h, u, f, p, d, m, g = new a,
			v = new r,
			_ = new a;
		this.render = function(r, a, o) {
			if(0 !== r.length) {
				void 0 === f && s(), n.useProgram(f), n.initAttributes(), n.enableAttribute(p.position), n.enableAttribute(p.uv), n.disableUnusedAttributes(), n.disable(e.CULL_FACE), n.enable(e.BLEND), e.bindBuffer(e.ARRAY_BUFFER, h), e.vertexAttribPointer(p.position, 2, e.FLOAT, !1, 16, 0), e.vertexAttribPointer(p.uv, 2, e.FLOAT, !1, 16, 8), e.bindBuffer(e.ELEMENT_ARRAY_BUFFER, u), e.uniformMatrix4fv(d.projectionMatrix, !1, o.projectionMatrix.elements), n.activeTexture(e.TEXTURE0), e.uniform1i(d.map, 0);
				var l = 0,
					y = 0,
					x = a.fog;
				x ? (e.uniform3f(d.fogColor, x.color.r, x.color.g, x.color.b), x.isFog && (e.uniform1f(d.fogNear, x.near), e.uniform1f(d.fogFar, x.far), e.uniform1i(d.fogType, 1), l = 1, y = 1)) : (e.uniform1i(d.fogType, 0), l = 0, y = 0);
				for(var b = 0, w = r.length; b < w; b++)(S = r[b]).modelViewMatrix.multiplyMatrices(o.matrixWorldInverse, S.matrixWorld), S.z = -S.modelViewMatrix.elements[14];
				r.sort(c);
				for(var M = [], b = 0, w = r.length; b < w; b++) {
					var S = r[b],
						G = S.material;
					if(!1 !== G.visible) {
						S.onBeforeRender(t, a, o, void 0, G, void 0), e.uniform1f(d.alphaTest, G.alphaTest), e.uniformMatrix4fv(d.modelViewMatrix, !1, S.modelViewMatrix.elements), S.matrixWorld.decompose(g, v, _), M[0] = _.x, M[1] = _.y;
						var E = 0;
						a.fog && G.fog && (E = y), l !== E && (e.uniform1i(d.fogType, E), l = E), null !== G.map ? (e.uniform2f(d.uvOffset, G.map.offset.x, G.map.offset.y), e.uniform2f(d.uvScale, G.map.repeat.x, G.map.repeat.y)) : (e.uniform2f(d.uvOffset, 0, 0), e.uniform2f(d.uvScale, 1, 1)), e.uniform1f(d.opacity, G.opacity), e.uniform3f(d.color, G.color.r, G.color.g, G.color.b), e.uniform1f(d.rotation, G.rotation), e.uniform2fv(d.scale, M), n.setBlending(G.blending, G.blendEquation, G.blendSrc, G.blendDst, G.blendEquationAlpha, G.blendSrcAlpha, G.blendDstAlpha, G.premultipliedAlpha), n.buffers.depth.setTest(G.depthTest), n.buffers.depth.setMask(G.depthWrite), n.buffers.color.setMask(G.colorWrite), i.setTexture2D(G.map || m, 0), e.drawElements(e.TRIANGLES, 6, e.UNSIGNED_SHORT, 0), S.onAfterRender(t, a, o, void 0, G, void 0)
					}
				}
				n.enable(e.CULL_FACE), n.reset()
			}
		}
	}

	function Q() {
		Object.defineProperty(this, "id", {
			value: qa++
		}), this.uuid = Oa.generateUUID(), this.name = "", this.type = "Material", this.fog = !0, this.lights = !0, this.blending = qi, this.side = Vi, this.flatShading = !1, this.vertexColors = Wi, this.opacity = 1, this.transparent = !1, this.blendSrc = lr, this.blendDst = cr, this.blendEquation = $i, this.blendSrcAlpha = null, this.blendDstAlpha = null, this.blendEquationAlpha = null, this.depthFunc = _r, this.depthTest = !0, this.depthWrite = !0, this.cs = null, this.clipIntersection = !1, this.clipShadows = !1, this.colorWrite = !0, this.precision = null, this.polygonOffset = !1, this.polygonOffsetFactor = 0, this.polygonOffsetUnits = 0, this.dithering = !1, this.alphaTest = 0, this.premultipliedAlpha = !1, this.overdraw = 0, this.visible = !0, this.userData = {}, this.needsUpdate = !0
	}

	function $(t) {
		Q.call(this), this.type = "MeshDepthMaterial", this.depthPacking = Ia, this.skinning = !1, this.morphTargets = !1, this.map = null, this.alphaMap = null, this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.wireframe = !1, this.wireframeLinewidth = 1, this.fog = !1, this.lights = !1, this.setValues(t)
	}

	function tt(t) {
		Q.call(this), this.type = "MeshDistanceMaterial", this.referencePosition = new a, this.nearDistance = 1, this.farDistance = 1e3, this.skinning = !1, this.morphTargets = !1, this.map = null, this.alphaMap = null, this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.fog = !1, this.lights = !1, this.setValues(t)
	}

	function et(t, e) {
		this.min = void 0 !== t ? t : new a(1 / 0, 1 / 0, 1 / 0), this.max = void 0 !== e ? e : new a(-1 / 0, -1 / 0, -1 / 0)
	}

	function nt(t, e) {
		this.center = void 0 !== t ? t : new a, this.radius = void 0 !== e ? e : 0
	}

	function it(t, e) {
		this.normal = void 0 !== t ? t : new a(1, 0, 0), this.constant = void 0 !== e ? e : 0
	}

	function rt(t, e, n, i, r, a) {
		this.planes = [void 0 !== t ? t : new it, void 0 !== e ? e : new it, void 0 !== n ? n : new it, void 0 !== i ? i : new it, void 0 !== r ? r : new it, void 0 !== a ? a : new it]
	}

	function at(t, e, r) {
		function o(e, n, i, r, a, o) {
			var s = e.geometry,
				l = null,
				c = y,
				h = e.customDepthMaterial;
			if(i && (c = x, h = e.customDistanceMaterial), h) l = h;
			else {
				var u = !1;
				n.morphTargets && (s && s.isBufferGeometry ? u = s.morphAttributes && s.morphAttributes.position && s.morphAttributes.position.length > 0 : s && s.isGeometry && (u = s.morphTargets && s.morphTargets.length > 0)), e.isSkinnedMesh && n.skinning;
				var f = e.isSkinnedMesh && n.skinning,
					p = 0;
				u && (p |= g), f && (p |= v), l = c[p]
			}
			if(t.ld && !0 === n.clipShadows && 0 !== n.cs.length) {
				var d = l.uuid,
					m = n.uuid,
					_ = b[d];
				void 0 === _ && (_ = {}, b[d] = _);
				var w = _[m];
				void 0 === w && (w = l.clone(), _[m] = w), l = w
			}
			l.visible = n.visible, l.wireframe = n.wireframe;
			var M = n.side;
			return C.renderSingleSided && M == Hi && (M = Vi), C.renderReverseSided && (M === Vi ? M = ji : M === ji && (M = Vi)), l.side = M, l.clipShadows = n.clipShadows, l.cs = n.cs, l.clipIntersection = n.clipIntersection, l.wireframeLinewidth = n.wireframeLinewidth, l.linewidth = n.linewidth, i && l.isMeshDistanceMaterial && (l.referencePosition.copy(r), l.nearDistance = a, l.farDistance = o), l
		}

		function s(n, i, r, a) {
			if(!1 !== n.visible) {
				if(n.layers.test(i.layers) && (n.isMesh || n.isLine || n.isPoints) && n.castShadow && (!n.frustumCulled || h.intersectsObject(n))) {
					n.modelViewMatrix.multiplyMatrices(r.matrixWorldInverse, n.matrixWorld);
					var l = e.update(n),
						c = n.material;
					if(Array.isArray(c))
						for(var u = l.groups, f = 0, p = u.length; f < p; f++) {
							var d = u[f],
								g = c[d.materialIndex];
							if(g && g.visible) {
								v = o(n, g, a, m, r.near, r.far);
								t.renderBufferDirect(r, null, l, v, n, d)
							}
						} else if(c.visible) {
							var v = o(n, c, a, m, r.near, r.far);
							t.renderBufferDirect(r, null, l, v, n, null)
						}
				}
				for(var _ = n.children, y = 0, x = _.length; y < x; y++) s(_[y], i, r, a)
			}
		}
		for(var h = new rt, u = new i, f = new n, p = new n(r, r), d = new a, m = new a, g = 1, v = 2, _ = 1 + (g | v), y = new Array(_), x = new Array(_), b = {}, w = [new a(1, 0, 0), new a(-1, 0, 0), new a(0, 0, 1), new a(0, 0, -1), new a(0, 1, 0), new a(0, -1, 0)], M = [new a(0, 1, 0), new a(0, 1, 0), new a(0, 1, 0), new a(0, 1, 0), new a(0, 0, 1), new a(0, 0, -1)], S = [new l, new l, new l, new l, new l, new l], G = 0; G !== _; ++G) {
			var E = 0 != (G & g),
				T = 0 != (G & v),
				A = new $({
					depthPacking: Ra,
					morphTargets: E,
					skinning: T
				});
			y[G] = A;
			var L = new tt({
				morphTargets: E,
				skinning: T
			});
			x[G] = L
		}
		var C = this;
		this.enabled = !1, this.autoUpdate = !0, this.needsUpdate = !1, this.type = ki, this.renderReverseSided = !0, this.renderSingleSided = !0, this.render = function(e, n, i) {
			if(!1 !== C.enabled && (!1 !== C.autoUpdate || !1 !== C.needsUpdate) && 0 !== e.length) {
				var r = t.context,
					a = t.state;
				a.disable(r.BLEND), a.buffers.color.setClear(1, 1, 1, 1), a.buffers.depth.setTest(!0), a.setScissorTest(!1);
				for(var o, l = 0, g = e.length; l < g; l++) {
					var v = e[l],
						_ = v.shadow,
						y = v && v.isPointLight;
					if(void 0 !== _) {
						var x = _.camera;
						if(f.copy(_.mapSize), f.min(p), y) {
							var b = f.x,
								G = f.y;
							S[0].set(2 * b, G, b, G), S[1].set(0, G, b, G), S[2].set(3 * b, G, b, G), S[3].set(b, G, b, G), S[4].set(3 * b, 0, b, G), S[5].set(b, 0, b, G), f.x *= 4, f.y *= 2
						}
						if(null === _.map) {
							var E = {
								minFilter: Br,
								magFilter: Br,
								format: sa
							};
							_.map = new c(f.x, f.y, E), _.map.texture.name = v.name + ".shadowMap", x.ux()
						}
						_.isSpotLightShadow && _.update(v);
						var T = _.map,
							A = _.matrix;
						m.setFromMatrixPosition(v.matrixWorld), x.position.copy(m), y ? (o = 6, A.makeTranslation(-m.x, -m.y, -m.z)) : (o = 1, d.setFromMatrixPosition(v.target.matrixWorld), x.lookAt(d), x.uld(), A.set(.5, 0, 0, .5, 0, .5, 0, .5, 0, 0, .5, .5, 0, 0, 0, 1), A.multiply(x.projectionMatrix), A.multiply(x.matrixWorldInverse)), t.setRenderTarget(T), t.clear();
						for(var L = 0; L < o; L++) {
							if(y) {
								d.copy(x.position), d.add(w[L]), x.up.copy(M[L]), x.lookAt(d), x.uld();
								var P = S[L];
								a.viewport(P)
							}
							u.multiplyMatrices(x.projectionMatrix, x.matrixWorldInverse), h.setFromMatrix(u), s(n, i, x, y)
						}
					}
				}
				C.needsUpdate = !1
			}
		}
	}

	function ot(t) {
		function e(e, n) {
			var i = e.array,
				r = e.dynamic ? t.DYNAMIC_DRAW : t.STATIC_DRAW,
				a = t.createBuffer();
			t.bindBuffer(n, a), t.bufferData(n, i, r), e.onUploadCallback();
			var o = t.FLOAT;
			return i instanceof Float32Array ? o = t.FLOAT : i instanceof Float64Array || (i instanceof Uint16Array ? o = t.UNSIGNED_SHORT : i instanceof Int16Array ? o = t.SHORT : i instanceof Uint32Array ? o = t.UNSIGNED_INT : i instanceof Int32Array ? o = t.INT : i instanceof Int8Array ? o = t.BYTE : i instanceof Uint8Array && (o = t.UNSIGNED_BYTE)), {
				buffer: a,
				type: o,
				bytesPerElement: i.BYTES_PER_ELEMENT,
				version: e.version
			}
		}

		function n(e, n, i) {
			var r = n.array,
				a = n.updateRange;
			t.bindBuffer(i, e), !1 === n.dynamic ? t.bufferData(i, r, t.STATIC_DRAW) : -1 === a.count ? t.bufferSubData(i, 0, r) : 0 === a.count || (t.bufferSubData(i, a.offset * r.BYTES_PER_ELEMENT, r.subarray(a.offset, a.offset + a.count)), a.count = -1)
		}
		var i = {};
		return {
			get: function(t) {
				return t.isInterleavedBufferAttribute && (t = t.data), i[t.uuid]
			},
			remove: function(e) {
				e.isInterleavedBufferAttribute && (e = e.data);
				var n = i[e.uuid];
				n && (t.deleteBuffer(n.buffer), delete i[e.uuid])
			},
			update: function(t, r) {
				t.isInterleavedBufferAttribute && (t = t.data);
				var a = i[t.uuid];
				void 0 === a ? i[t.uuid] = e(t, r) : a.version < t.version && (n(a.buffer, t, r), a.version = t.version)
			}
		}
	}

	function st(t, e, n, i) {
		this._x = t || 0, this._y = e || 0, this._z = n || 0, this._order = i || st.DefaultOrder
	}

	function lt() {
		this.mask = 1
	}

	function ct() {
		Object.defineProperty(this, "id", {
			value: Za++
		}), this.uuid = Oa.generateUUID(), this.name = "", this.type = "Object3D", this.parent = null, this.children = [], this.up = ct.DefaultUp.clone();
		var t = new a,
			e = new st,
			n = new r,
			s = new a(1, 1, 1);
		e.onChange(function() {
			n.setFromEuler(e, !1)
		}), n.onChange(function() {
			e.setFromQuaternion(n, void 0, !1)
		}), Object.defineProperties(this, {
			position: {
				enumerable: !0,
				value: t
			},
			rotation: {
				enumerable: !0,
				value: e
			},
			quaternion: {
				enumerable: !0,
				value: n
			},
			scale: {
				enumerable: !0,
				value: s
			},
			modelViewMatrix: {
				value: new i
			},
			normalMatrix: {
				value: new o
			}
		}), this.matrix = new i, this.matrixWorld = new i, this.matrixAutoUpdate = ct.DefaultMatrixAutoUpdate, this.mte = !1, this.layers = new lt, this.visible = !0, this.castShadow = !1, this.receiveShadow = !1, this.frustumCulled = !0, this.renderOrder = 0, this.userData = {}
	}

	function ht() {
		ct.call(this), this.type = "Camera", this.matrixWorldInverse = new i, this.projectionMatrix = new i
	}

	function ut(t, e, n, i, r, a) {
		ht.call(this), this.type = "OrthographicCamera", this.zoom = 1, this.view = null, this.left = t, this.right = e, this.top = n, this.bottom = i, this.near = void 0 !== r ? r : .1, this.far = void 0 !== a ? a : 2e3, this.ux()
	}

	function ft(t, e, n, i, r, o) {
		this.a = t, this.b = e, this.c = n, this.normal = i && i.isVector3 ? i : new a, this.vertexNormals = Array.isArray(i) ? i : [], this.color = r && r.isColor ? r : new Y, this.vertexColors = Array.isArray(r) ? r : [], this.materialIndex = void 0 !== o ? o : 0
	}

	function pt() {
		Object.defineProperty(this, "id", {
			value: Ja += 2
		}), this.uuid = Oa.generateUUID(), this.name = "", this.type = "Geometry", this.vertices = [], this.colors = [], this.faces = [], this.faceVertexUvs = [
			[]
		], this.morphTargets = [], this.morphNormals = [], this.skinWeights = [], this.skinIndices = [], this.lineDistances = [], this.boundingBox = null, this.boundingSphere = null, this.elementsNeedUpdate = !1, this.verticesNeedUpdate = !1, this.uvsNeedUpdate = !1, this.normalsNeedUpdate = !1, this.colorsNeedUpdate = !1, this.lineDistancesNeedUpdate = !1, this.groupsNeedUpdate = !1
	}

	function dt(t, e, n) {
		this.uuid = Oa.generateUUID(), this.name = "", this.array = t, this.itemSize = e, this.count = void 0 !== t ? t.length / e : 0, this.normalized = !0 === n, this.dynamic = !1, this.updateRange = {
			offset: 0,
			count: -1
		}, this.onUploadCallback = function() {}, this.version = 0
	}

	function mt(t, e, n) {
		dt.call(this, new Int8Array(t), e, n)
	}

	function gt(t, e, n) {
		dt.call(this, new Uint8Array(t), e, n)
	}

	function vt(t, e, n) {
		dt.call(this, new Uint8ClampedArray(t), e, n)
	}

	function _t(t, e, n) {
		dt.call(this, new Int16Array(t), e, n)
	}

	function yt(t, e, n) {
		dt.call(this, new Uint16Array(t), e, n)
	}

	function xt(t, e, n) {
		dt.call(this, new Int32Array(t), e, n)
	}

	function bt(t, e, n) {
		dt.call(this, new Uint32Array(t), e, n)
	}

	function wt(t, e, n) {
		dt.call(this, new Float32Array(t), e, n)
	}

	function Mt(t, e, n) {
		dt.call(this, new Float64Array(t), e, n)
	}

	function St() {
		this.indices = [], this.vertices = [], this.normals = [], this.colors = [], this.uvs = [], this.uvs2 = [], this.groups = [], this.morphTargets = {}, this.skinWeights = [], this.skinIndices = [], this.boundingBox = null, this.boundingSphere = null, this.verticesNeedUpdate = !1, this.normalsNeedUpdate = !1, this.colorsNeedUpdate = !1, this.uvsNeedUpdate = !1, this.groupsNeedUpdate = !1
	}

	function Gt(t) {
		if(0 === t.length) return -1 / 0;
		for(var e = t[0], n = 1, i = t.length; n < i; ++n) t[n] > e && (e = t[n]);
		return e
	}

	function Et() {
		Object.defineProperty(this, "id", {
			value: Ka += 2
		}), this.uuid = Oa.generateUUID(), this.name = "", this.type = "BufferGeometry", this.index = null, this.attributes = {}, this.morphAttributes = {}, this.groups = [], this.boundingBox = null, this.boundingSphere = null, this.drawRange = {
			start: 0,
			count: 1 / 0
		}
	}

	function Tt(t, e, n, i, r, a) {
		pt.call(this), this.type = "BoxGeometry", this.parameters = {
			width: t,
			height: e,
			depth: n,
			widthSegments: i,
			heightSegments: r,
			depthSegments: a
		}, this.fromBufferGeometry(new At(t, e, n, i, r, a)), this.mergeVertices()
	}

	function At(t, e, n, i, r, o) {
		function s(t, e, n, i, r, o, s, m, g, v, _) {
			var y, x, b = o / g,
				w = s / v,
				M = o / 2,
				S = s / 2,
				G = m / 2,
				E = g + 1,
				T = v + 1,
				A = 0,
				L = 0,
				C = new a;
			for(x = 0; x < T; x++) {
				var P = x * w - S;
				for(y = 0; y < E; y++) {
					var I = y * b - M;
					C[t] = I * i, C[e] = P * r, C[n] = G, h.push(C.x, C.y, C.z), C[t] = 0, C[e] = 0, C[n] = m > 0 ? 1 : -1, u.push(C.x, C.y, C.z), f.push(y / g), f.push(1 - x / v), A += 1
				}
			}
			for(x = 0; x < v; x++)
				for(y = 0; y < g; y++) {
					var R = p + y + E * x,
						O = p + y + E * (x + 1),
						N = p + (y + 1) + E * (x + 1),
						D = p + (y + 1) + E * x;
					c.push(R, O, D), c.push(O, N, D), L += 6
				}
			l.addGroup(d, L, _), d += L, p += A
		}
		Et.call(this), this.type = "By", this.parameters = {
			width: t,
			height: e,
			depth: n,
			widthSegments: i,
			heightSegments: r,
			depthSegments: o
		};
		var l = this;
		t = t || 1, e = e || 1, n = n || 1, i = Math.floor(i) || 1, r = Math.floor(r) || 1;
		var c = [],
			h = [],
			u = [],
			f = [],
			p = 0,
			d = 0;
		s("z", "y", "x", -1, -1, n, e, t, o = Math.floor(o) || 1, r, 0), s("z", "y", "x", 1, -1, n, e, -t, o, r, 1), s("x", "z", "y", 1, 1, t, n, e, i, o, 2), s("x", "z", "y", 1, -1, t, n, -e, i, o, 3), s("x", "y", "z", 1, -1, t, e, n, i, r, 4), s("x", "y", "z", -1, -1, t, e, -n, i, r, 5), this.setIndex(c), this.addAttribute("position", new wt(h, 3)), this.addAttribute("normal", new wt(u, 3)), this.addAttribute("uv", new wt(f, 2))
	}

	function Lt(t, e, n, i) {
		pt.call(this), this.type = "PlaneGeometry", this.parameters = {
			width: t,
			height: e,
			widthSegments: n,
			heightSegments: i
		}, this.fromBufferGeometry(new Ct(t, e, n, i)), this.mergeVertices()
	}

	function Ct(t, e, n, i) {
		Et.call(this), this.type = "PlaneBufferGeometry", this.parameters = {
			width: t,
			height: e,
			widthSegments: n,
			heightSegments: i
		};
		var r, a, o = (t = t || 1) / 2,
			s = (e = e || 1) / 2,
			l = Math.floor(n) || 1,
			c = Math.floor(i) || 1,
			h = l + 1,
			u = c + 1,
			f = t / l,
			p = e / c,
			d = [],
			m = [],
			g = [],
			v = [];
		for(a = 0; a < u; a++) {
			var _ = a * p - s;
			for(r = 0; r < h; r++) {
				var y = r * f - o;
				m.push(y, -_, 0), g.push(0, 0, 1), v.push(r / l), v.push(1 - a / c)
			}
		}
		for(a = 0; a < c; a++)
			for(r = 0; r < l; r++) {
				var x = r + h * a,
					b = r + h * (a + 1),
					w = r + 1 + h * (a + 1),
					M = r + 1 + h * a;
				d.push(x, b, M), d.push(b, w, M)
			}
		this.setIndex(d), this.addAttribute("position", new wt(m, 3)), this.addAttribute("normal", new wt(g, 3)), this.addAttribute("uv", new wt(v, 2))
	}

	function Pt(t) {
		Q.call(this), this.type = "Mal", this.color = new Y(16777215), this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.specularMap = null, this.alphaMap = null, this.envMap = null, this.combine = Mr, this.reflectivity = 1, this.refractionRatio = .98, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.skinning = !1, this.morphTargets = !1, this.lights = !1, this.setValues(t)
	}

	function It(t) {
		Q.call(this), this.type = "ShaderMaterial", this.defines = {}, this.uniforms = {}, this.vertexShader = "void main() {\n\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n}", this.fragmentShader = "void main() {\n\tgl_FragColor = vec4( 1.0, 0.0, 0.0, 1.0 );\n}", this.linewidth = 1, this.wireframe = !1, this.wireframeLinewidth = 1, this.fog = !1, this.lights = !1, this.clipping = !1, this.skinning = !1, this.morphTargets = !1, this.morphNormals = !1, this.extensions = {
			derivatives: !1,
			fragDepth: !1,
			drawBuffers: !1,
			shaderTextureLOD: !1
		}, this.defaultAttributeValues = {
			color: [1, 1, 1],
			uv: [0, 0],
			uv2: [0, 0]
		}, this.index0AttributeName = void 0, void 0 !== t && (t.attributes, this.setValues(t))
	}

	function Rt(t, e) {
		this.origin = void 0 !== t ? t : new a, this.direction = void 0 !== e ? e : new a
	}

	function Ot(t, e) {
		this.start = void 0 !== t ? t : new a, this.end = void 0 !== e ? e : new a
	}

	function Nt(t, e, n) {
		this.a = void 0 !== t ? t : new a, this.b = void 0 !== e ? e : new a, this.c = void 0 !== n ? n : new a
	}

	function Dt(t, e) {
		ct.call(this), this.type = "Mesh", this.geometry = void 0 !== t ? t : new Et, this.material = void 0 !== e ? e : new Pt({
			color: 16777215 * Math.random()
		}), this.drawMode = wa, this.updateMorphTargets()
	}

	function zt(t, e, n, i) {
		function r(t, n) {
			e.buffers.color.setClear(t.r, t.g, t.b, n, i)
		}
		var a, o, s, l = new Y(0),
			c = 0;
		return {
			getClearColor: function() {
				return l
			},
			sr: function(t, e) {
				l.set(t), r(l, c = void 0 !== e ? e : 1)
			},
			getClearAlpha: function() {
				return c
			},
			setClearAlpha: function(t) {
				r(l, c = t)
			},
			render: function(e, i, h, u) {
				var f = i.background;
				null === f ? r(l, c) : f && f.isColor && (r(f, 1), u = !0), (t.autoClear || u) && t.clear(t.autoClearColor, t.autoClearDepth, t.autoClearStencil), f && f.isCubeTexture ? (void 0 === s && ((s = new Dt(new At(1, 1, 1), new It({
					uniforms: Ya.cube.uniforms,
					vertexShader: Ya.cube.vertexShader,
					fragmentShader: Ya.cube.fragmentShader,
					side: ji,
					depthTest: !0,
					depthWrite: !1,
					fog: !1
				}))).geometry.removeAttribute("normal"), s.geometry.removeAttribute("uv"), s.onBeforeRender = function(t, e, n) {
					this.matrixWorld.copyPosition(n.matrixWorld)
				}, n.update(s.geometry)), s.material.uniforms.tCube.value = f, e.push(s, s.geometry, s.material, 0, null)) : f && f.isTexture && (void 0 === a && (a = new ut(-1, 1, 1, -1, 0, 1), o = new Dt(new Ct(2, 2), new Pt({
					depthTest: !1,
					depthWrite: !1,
					fog: !1
				})), n.update(o.geometry)), o.material.map = f, t.renderBufferDirect(a, null, o.geometry, o.material, o, null))
			}
		}
	}

	function Ut(t, e) {
		return t.renderOrder !== e.renderOrder ? t.renderOrder - e.renderOrder : t.program && e.program && t.program !== e.program ? t.program.id - e.program.id : t.material.id !== e.material.id ? t.material.id - e.material.id : t.z !== e.z ? t.z - e.z : t.id - e.id
	}

	function Ft(t, e) {
		return t.renderOrder !== e.renderOrder ? t.renderOrder - e.renderOrder : t.z !== e.z ? e.z - t.z : t.id - e.id
	}

	function kt() {
		var t = [],
			e = 0,
			n = [],
			i = [];
		return {
			opaque: n,
			transparent: i,
			init: function() {
				e = 0, n.length = 0, i.length = 0
			},
			push: function(r, a, o, s, l) {
				var c = t[e];
				void 0 === c ? (c = {
					id: r.id,
					object: r,
					geometry: a,
					material: o,
					program: o.program,
					renderOrder: r.renderOrder,
					z: s,
					group: l
				}, t[e] = c) : (c.id = r.id, c.object = r, c.geometry = a, c.material = o, c.program = o.program, c.renderOrder = r.renderOrder, c.z = s, c.group = l), (!0 === o.transparent ? i : n).push(c), e++
			},
			sort: function() {
				n.length > 1 && n.sort(Ut), i.length > 1 && i.sort(Ft)
			}
		}
	}

	function Bt() {
		var t = {};
		return {
			get: function(e, n) {
				var i = e.id + "," + n.id,
					r = t[i];
				return void 0 === r && (r = new kt, t[i] = r), r
			},
			dispose: function() {
				t = {}
			}
		}
	}

	function Vt(t, e) {
		return Math.abs(e[1]) - Math.abs(t[1])
	}

	function jt(t) {
		var e = {},
			n = new Float32Array(8);
		return {
			update: function(i, r, a, o) {
				var s = i.morphTargetInfluences,
					l = s.length,
					c = e[r.id];
				if(void 0 === c) {
					for(c = [], f = 0; f < l; f++) c[f] = [f, 0];
					e[r.id] = c
				}
				for(var h = a.morphTargets && r.morphAttributes.position, u = a.morphNormals && r.morphAttributes.normal, f = 0; f < l; f++) 0 !== (p = c[f])[1] && (h && r.removeAttribute("morphTarget" + f), u && r.removeAttribute("morphNormal" + f));
				for(f = 0; f < l; f++)(p = c[f])[0] = f, p[1] = s[f];
				c.sort(Vt);
				for(f = 0; f < 8; f++) {
					var p = c[f];
					if(p) {
						var d = p[0],
							m = p[1];
						if(m) {
							h && r.addAttribute("morphTarget" + f, h[d]), u && r.addAttribute("morphNormal" + f, u[d]), n[f] = m;
							continue
						}
					}
					n[f] = 0
				}
				o.getUniforms().setValue(t, "morphTargetInfluences", n)
			}
		}
	}

	function Ht(t, e, n) {
		var i, r, a;
		this.setMode = function(t) {
			i = t
		}, this.setIndex = function(t) {
			r = t.type, a = t.bytesPerElement
		}, this.render = function(e, o) {
			t.drawElements(i, o, r, e * a), n.calls++, n.vertices += o, i === t.TRIANGLES ? n.faces += o / 3 : i === t.POINTS && (n.points += o)
		}, this.renderInstances = function(o, s, l) {
			var c = e.get("ANGLE_instanced_arrays");
			null !== c && (c.drawElementsInstancedANGLE(i, l, r, s * a, o.maxInstancedCount), n.calls++, n.vertices += l * o.maxInstancedCount, i === t.TRIANGLES ? n.faces += o.maxInstancedCount * l / 3 : i === t.POINTS && (n.points += o.maxInstancedCount * l))
		}
	}

	function Wt(t, e, n) {
		var i;
		this.setMode = function(t) {
			i = t
		}, this.render = function(e, r) {
			t.drawArrays(i, e, r), n.calls++, n.vertices += r, i === t.TRIANGLES ? n.faces += r / 3 : i === t.POINTS && (n.points += r)
		}, this.renderInstances = function(r, a, o) {
			var s = e.get("ANGLE_instanced_arrays");
			if(null !== s) {
				var l = r.attributes.position;
				l.isInterleavedBufferAttribute ? (o = l.data.count, s.drawArraysInstancedANGLE(i, 0, o, r.maxInstancedCount)) : s.drawArraysInstancedANGLE(i, a, o, r.maxInstancedCount), n.calls++, n.vertices += o * r.maxInstancedCount, i === t.TRIANGLES ? n.faces += r.maxInstancedCount * o / 3 : i === t.POINTS && (n.points += r.maxInstancedCount * o)
			}
		}
	}

	function Xt(t, e, n) {
		function i(t) {
			var o = t.target,
				s = r[o.id];
			null !== s.index && e.remove(s.index);
			for(var l in s.attributes) e.remove(s.attributes[l]);
			o.removeEventListener("dispose", i), delete r[o.id];
			var c = a[o.id];
			c && (e.remove(c), delete a[o.id]), (c = a[s.id]) && (e.remove(c), delete a[s.id]), n.geometries--
		}
		var r = {},
			a = {};
		return {
			get: function(t, e) {
				var a = r[e.id];
				return a || (e.addEventListener("dispose", i), e.isBufferGeometry ? a = e : e.isGeometry && (void 0 === e._bufferGeometry && (e._bufferGeometry = (new Et).st(t)), a = e._bufferGeometry), r[e.id] = a, n.geometries++, a)
			},
			update: function(n) {
				var i = n.index,
					r = n.attributes;
				null !== i && e.update(i, t.ELEMENT_ARRAY_BUFFER);
				for(var a in r) e.update(r[a], t.ARRAY_BUFFER);
				var o = n.morphAttributes;
				for(var a in o)
					for(var s = o[a], l = 0, c = s.length; l < c; l++) e.update(s[l], t.ARRAY_BUFFER)
			},
			getWireframeAttribute: function(n) {
				var i = a[n.id];
				if(i) return i;
				var r = [],
					o = n.index,
					s = n.attributes;
				if(null !== o)
					for(var l = 0, c = (p = o.array).length; l < c; l += 3) {
						var h = p[l + 0],
							u = p[l + 1],
							f = p[l + 2];
						r.push(h, u, u, f, f, h)
					} else
						for(var p = s.position.array, l = 0, c = p.length / 3 - 1; l < c; l += 3) {
							var h = l + 0,
								u = l + 1,
								f = l + 2;
							r.push(h, u, u, f, f, h)
						}
				return i = new(Gt(r) > 65535 ? bt : yt)(r, 1), e.update(i, t.ELEMENT_ARRAY_BUFFER), a[n.id] = i, i
			}
		}
	}

	function Yt() {
		var t = {};
		return {
			get: function(e) {
				if(void 0 !== t[e.id]) return t[e.id];
				var i;
				switch(e.type) {
					case "Dt":
						i = {
							direction: new a,
							color: new Y,
							shadow: !1,
							shadowBias: 0,
							shadowRadius: 1,
							shadowMapSize: new n
						};
						break;
					case "SpotLight":
						i = {
							position: new a,
							direction: new a,
							color: new Y,
							distance: 0,
							coneCos: 0,
							penumbraCos: 0,
							decay: 0,
							shadow: !1,
							shadowBias: 0,
							shadowRadius: 1,
							shadowMapSize: new n
						};
						break;
					case "PointLight":
						i = {
							position: new a,
							color: new Y,
							distance: 0,
							decay: 0,
							shadow: !1,
							shadowBias: 0,
							shadowRadius: 1,
							shadowMapSize: new n,
							shadowCameraNear: 1,
							shadowCameraFar: 1e3
						};
						break;
					case "HemisphereLight":
						i = {
							direction: new a,
							skyColor: new Y,
							groundColor: new Y
						};
						break;
					case "RectAreaLight":
						i = {
							color: new Y,
							position: new a,
							halfWidth: new a,
							halfHeight: new a
						}
				}
				return t[e.id] = i, i
			}
		}
	}

	function qt() {
		var t = new Yt,
			e = {
				hash: "",
				ambient: [0, 0, 0],
				directional: [],
				directionalShadowMap: [],
				directionalShadowMatrix: [],
				spot: [],
				spotShadowMap: [],
				spotShadowMatrix: [],
				rectArea: [],
				point: [],
				pointShadowMap: [],
				pointShadowMatrix: [],
				hemi: []
			},
			n = new a,
			r = new i,
			o = new i;
		return {
			setup: function(i, a, s) {
				for(var l = 0, c = 0, h = 0, u = 0, f = 0, p = 0, d = 0, m = 0, g = s.matrixWorldInverse, v = 0, _ = i.length; v < _; v++) {
					var y = i[v],
						x = y.color,
						b = y.intensity,
						w = y.distance,
						M = y.shadow && y.shadow.map ? y.shadow.map.texture : null;
					if(y.isAmbientLight) l += x.r * b, c += x.g * b, h += x.b * b;
					else if(y.isDt)(G = t.get(y)).color.copy(y.color).multiplyScalar(y.intensity), G.direction.setFromMatrixPosition(y.matrixWorld), n.setFromMatrixPosition(y.target.matrixWorld), G.direction.sub(n), G.direction.transformDirection(g), G.shadow = y.castShadow, y.castShadow && (S = y.shadow, G.shadowBias = S.bias, G.shadowRadius = S.radius, G.shadowMapSize = S.mapSize), e.directionalShadowMap[u] = M, e.directionalShadowMatrix[u] = y.shadow.matrix, e.directional[u] = G, u++;
					else if(y.isSpotLight)(G = t.get(y)).position.setFromMatrixPosition(y.matrixWorld), G.position.applyMatrix4(g), G.color.copy(x).multiplyScalar(b), G.distance = w, G.direction.setFromMatrixPosition(y.matrixWorld), n.setFromMatrixPosition(y.target.matrixWorld), G.direction.sub(n), G.direction.transformDirection(g), G.coneCos = Math.cos(y.angle), G.penumbraCos = Math.cos(y.angle * (1 - y.penumbra)), G.decay = 0 === y.distance ? 0 : y.decay, G.shadow = y.castShadow, y.castShadow && (S = y.shadow, G.shadowBias = S.bias, G.shadowRadius = S.radius, G.shadowMapSize = S.mapSize), e.spotShadowMap[p] = M, e.spotShadowMatrix[p] = y.shadow.matrix, e.spot[p] = G, p++;
					else if(y.isRectAreaLight)(G = t.get(y)).color.copy(x).multiplyScalar(b / (y.width * y.height)), G.position.setFromMatrixPosition(y.matrixWorld), G.position.applyMatrix4(g), o.identity(), r.copy(y.matrixWorld), r.premultiply(g), o.extractRotation(r), G.halfWidth.set(.5 * y.width, 0, 0), G.halfHeight.set(0, .5 * y.height, 0), G.halfWidth.applyMatrix4(o), G.halfHeight.applyMatrix4(o), e.rectArea[d] = G, d++;
					else if(y.isPointLight) {
						if((G = t.get(y)).position.setFromMatrixPosition(y.matrixWorld), G.position.applyMatrix4(g), G.color.copy(y.color).multiplyScalar(y.intensity), G.distance = y.distance, G.decay = 0 === y.distance ? 0 : y.decay, G.shadow = y.castShadow, y.castShadow) {
							var S = y.shadow;
							G.shadowBias = S.bias, G.shadowRadius = S.radius, G.shadowMapSize = S.mapSize, G.shadowCameraNear = S.camera.near, G.shadowCameraFar = S.camera.far
						}
						e.pointShadowMap[f] = M, e.pointShadowMatrix[f] = y.shadow.matrix, e.point[f] = G, f++
					} else if(y.isHemisphereLight) {
						var G = t.get(y);
						G.direction.setFromMatrixPosition(y.matrixWorld), G.direction.transformDirection(g), G.direction.normalize(), G.skyColor.copy(y.color).multiplyScalar(b), G.groundColor.copy(y.groundColor).multiplyScalar(b), e.hemi[m] = G, m++
					}
				}
				e.ambient[0] = l, e.ambient[1] = c, e.ambient[2] = h, e.directional.length = u, e.spot.length = p, e.rectArea.length = d, e.point.length = f, e.hemi.length = m, e.hash = u + "," + f + "," + p + "," + d + "," + m + "," + a.length
			},
			state: e
		}
	}

	function Zt(t, e) {
		var n = {};
		return {
			update: function(i) {
				var r = e.frame,
					a = i.geometry,
					o = t.get(i, a);
				return n[o.id] !== r && (a.isGeometry && o.updateFromObject(i), t.update(o), n[o.id] = r), o
			},
			clear: function() {
				n = {}
			}
		}
	}

	function Jt(t, e, n) {
		var i = t.createShader(e);
		return t.shaderSource(i, n), t.compileShader(i), t.getShaderParameter(i, t.COMPILE_STATUS), t.getShaderInfoLog(i), i
	}

	function Kt(t) {
		switch(t) {
			case Ga:
				return ["Linear", "( value )"];
			case Ea:
				return ["sRGB", "( value )"];
			case Aa:
				return ["RGBE", "( value )"];
			case La:
				return ["RGBM", "( value, 7.0 )"];
			case Ca:
				return ["RGBM", "( value, 16.0 )"];
			case Pa:
				return ["RGBD", "( value, 256.0 )"];
			case Ta:
				return ["Gamma", "( value, float( GAMMA_FACTOR ) )"]
		}
	}

	function Qt(t, e) {
		var n = Kt(e);
		return "vec4 " + t + "( vec4 value ) { return " + n[0] + "ToLinear" + n[1] + "; }"
	}

	function $t(t, e) {
		var n = Kt(e);
		return "vec4 " + t + "( vec4 value ) { return LinearTo" + n[0] + n[1] + "; }"
	}

	function te(t, e) {
		var n;
		switch(e) {
			case Tr:
				n = "Linear";
				break;
			case Ar:
				n = "Reinhard";
				break;
			case Lr:
				n = "Uncharted2";
				break;
			case Cr:
				n = "OptimizedCineon"
		}
		return "vec3 " + t + "( vec3 color ) { return " + n + "ToneMapping( color ); }"
	}

	function ee(t, e, n) {
		return [(t = t || {}).derivatives || e.envMapCubeUV || e.bumpMap || e.normalMap || e.flatShading ? "#extension GL_OES_standard_derivatives : enable" : "", (t.fragDepth || e.logarithmicDepthBuffer) && n.get("EXT_frag_depth") ? "#extension GL_EXT_frag_depth : enable" : "", t.drawBuffers && n.get("WEBGL_draw_buffers") ? "#extension GL_EXT_draw_buffers : require" : "", (t.shaderTextureLOD || e.envMap) && n.get("EXT_shader_texture_lod") ? "#extension GL_EXT_shader_texture_lod : enable" : ""].filter(re).join("\n")
	}

	function ne(t) {
		var e = [];
		for(var n in t) {
			var i = t[n];
			!1 !== i && e.push("#define " + n + " " + i)
		}
		return e.join("\n")
	}

	function ie(t, e) {
		for(var n = {}, i = t.getProgramParameter(e, t.ACTIVE_ATTRIBUTES), r = 0; r < i; r++) {
			var a = t.getActiveAttrib(e, r).name;
			n[a] = t.getAttribLocation(e, a)
		}
		return n
	}

	function re(t) {
		return "" !== t
	}

	function ae(t, e) {
		return t.replace(/NUM_DIR_LIGHTS/g, e.numDirLights).replace(/NUM_SPOT_LIGHTS/g, e.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g, e.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g, e.numPointLights).replace(/NUM_HEMI_LIGHTS/g, e.numHemiLights)
	}

	function oe(t) {
		var e = /^[ \t]*#include +<([\w\d.]+)>/gm;
		return t.replace(e, function(t, e) {
			return oe(Xa[e])
		})
	}

	function se(t) {
		var e = /for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g;
		return t.replace(e, function(t, e, n, i) {
			for(var r = "", a = parseInt(e); a < parseInt(n); a++) r += i.replace(/\[ i \]/g, "[ " + a + " ]");
			return r
		})
	}

	function le(t, e, n, i, r, a) {
		var o = t.context,
			s = i.defines,
			l = r.vertexShader,
			c = r.fragmentShader,
			h = "SHADOWMAP_TYPE_BASIC";
		a.shadowMapType === ki ? h = "SHADOWMAP_TYPE_PCF" : a.shadowMapType === Bi && (h = "SHADOWMAP_TYPE_PCF_SOFT");
		var u = "ENVMAP_TYPE_CUBE",
			f = "ENVMAP_MODE_REFLECTION",
			p = "ENVMAP_BLENDING_MULTIPLY";
		if(a.envMap) {
			switch(i.envMap.mapping) {
				case Pr:
				case Ir:
					u = "ENVMAP_TYPE_CUBE";
					break;
				case Dr:
				case zr:
					u = "ENVMAP_TYPE_CUBE_UV";
					break;
				case Rr:
				case Or:
					u = "ENVMAP_TYPE_EQUIREC";
					break;
				case Nr:
					u = "ENVMAP_TYPE_SPHERE"
			}
			switch(i.envMap.mapping) {
				case Ir:
				case Or:
					f = "ENVMAP_MODE_REFRACTION"
			}
			switch(i.combine) {
				case Mr:
					p = "ENVMAP_BLENDING_MULTIPLY";
					break;
				case Sr:
					p = "ENVMAP_BLENDING_MIX";
					break;
				case Gr:
					p = "ENVMAP_BLENDING_ADD"
			}
		}
		var d, m, g = t.gammaFactor > 0 ? t.gammaFactor : 1,
			v = ee(i.extensions, a, e),
			_ = ne(s),
			y = o.createProgram();
		i.isRawShaderMaterial ? ((d = [_].filter(re).join("\n")).length > 0 && (d += "\n"), (m = [v, _].filter(re).join("\n")).length > 0 && (m += "\n")) : (d = ["precision " + a.precision + " float;", "precision " + a.precision + " int;", "#define SHADER_NAME " + r.name, _, a.supportsVertexTextures ? "#define VERTEX_TEXTURES" : "", "#define GAMMA_FACTOR " + g, "#define MAX_BONES " + a.maxBones, a.useFog && a.fog ? "#define USE_FOG" : "", a.useFog && a.fogExp ? "#define FOG_EXP2" : "", a.map ? "#define USE_MAP" : "", a.envMap ? "#define USE_ENVMAP" : "", a.envMap ? "#define " + f : "", a.lightMap ? "#define USE_LIGHTMAP" : "", a.aoMap ? "#define USE_AOMAP" : "", a.emissiveMap ? "#define USE_EMISSIVEMAP" : "", a.bumpMap ? "#define USE_BUMPMAP" : "", a.normalMap ? "#define USE_NORMALMAP" : "", a.displacementMap && a.supportsVertexTextures ? "#define USE_DISPLACEMENTMAP" : "", a.specularMap ? "#define USE_SPECULARMAP" : "", a.roughnessMap ? "#define USE_ROUGHNESSMAP" : "", a.metalnessMap ? "#define USE_METALNESSMAP" : "", a.alphaMap ? "#define USE_ALPHAMAP" : "", a.vertexColors ? "#define USE_COLOR" : "", a.flatShading ? "#define FLAT_SHADED" : "", a.skinning ? "#define USE_SKINNING" : "", a.useVertexTexture ? "#define BONE_TEXTURE" : "", a.morphTargets ? "#define USE_MORPHTARGETS" : "", a.morphNormals && !1 === a.flatShading ? "#define USE_MORPHNORMALS" : "", a.doubleSided ? "#define DOUBLE_SIDED" : "", a.flipSided ? "#define FLIP_SIDED" : "", "#define NUM_CLIPPING_PLANES " + a.numClippingPlanes, a.shadowMapEnabled ? "#define USE_SHADOWMAP" : "", a.shadowMapEnabled ? "#define " + h : "", a.sizeAttenuation ? "#define USE_SIZEATTENUATION" : "", a.logarithmicDepthBuffer ? "#define USE_LOGDEPTHBUF" : "", a.logarithmicDepthBuffer && e.get("EXT_frag_depth") ? "#define USE_LOGDEPTHBUF_EXT" : "", "uniform mat4 modelMatrix;", "uniform mat4 modelViewMatrix;", "uniform mat4 projectionMatrix;", "uniform mat4 viewMatrix;", "uniform mat3 normalMatrix;", "uniform vec3 cameraPosition;", "attribute vec3 position;", "attribute vec3 normal;", "attribute vec2 uv;", "#ifdef USE_COLOR", "\tattribute vec3 color;", "#endif", "#ifdef USE_MORPHTARGETS", "\tattribute vec3 morphTarget0;", "\tattribute vec3 morphTarget1;", "\tattribute vec3 morphTarget2;", "\tattribute vec3 morphTarget3;", "\t#ifdef USE_MORPHNORMALS", "\t\tattribute vec3 morphNormal0;", "\t\tattribute vec3 morphNormal1;", "\t\tattribute vec3 morphNormal2;", "\t\tattribute vec3 morphNormal3;", "\t#else", "\t\tattribute vec3 morphTarget4;", "\t\tattribute vec3 morphTarget5;", "\t\tattribute vec3 morphTarget6;", "\t\tattribute vec3 morphTarget7;", "\t#endif", "#endif", "#ifdef USE_SKINNING", "\tattribute vec4 skinIndex;", "\tattribute vec4 skinWeight;", "#endif", "\n"].filter(re).join("\n"), m = [v, "precision " + a.precision + " float;", "precision " + a.precision + " int;", "#define SHADER_NAME " + r.name, _, a.alphaTest ? "#define ALPHATEST " + a.alphaTest : "", "#define GAMMA_FACTOR " + g, a.useFog && a.fog ? "#define USE_FOG" : "", a.useFog && a.fogExp ? "#define FOG_EXP2" : "", a.map ? "#define USE_MAP" : "", a.envMap ? "#define USE_ENVMAP" : "", a.envMap ? "#define " + u : "", a.envMap ? "#define " + f : "", a.envMap ? "#define " + p : "", a.lightMap ? "#define USE_LIGHTMAP" : "", a.aoMap ? "#define USE_AOMAP" : "", a.emissiveMap ? "#define USE_EMISSIVEMAP" : "", a.bumpMap ? "#define USE_BUMPMAP" : "", a.normalMap ? "#define USE_NORMALMAP" : "", a.specularMap ? "#define USE_SPECULARMAP" : "", a.roughnessMap ? "#define USE_ROUGHNESSMAP" : "", a.metalnessMap ? "#define USE_METALNESSMAP" : "", a.alphaMap ? "#define USE_ALPHAMAP" : "", a.vertexColors ? "#define USE_COLOR" : "", a.gradientMap ? "#define USE_GRADIENTMAP" : "", a.flatShading ? "#define FLAT_SHADED" : "", a.doubleSided ? "#define DOUBLE_SIDED" : "", a.flipSided ? "#define FLIP_SIDED" : "", "#define NUM_CLIPPING_PLANES " + a.numClippingPlanes, "#define UNION_CLIPPING_PLANES " + (a.numClippingPlanes - a.numClipIntersection), a.shadowMapEnabled ? "#define USE_SHADOWMAP" : "", a.shadowMapEnabled ? "#define " + h : "", a.premultipliedAlpha ? "#define PREMULTIPLIED_ALPHA" : "", a.physicallyCorrectLights ? "#define PHYSICALLY_CORRECT_LIGHTS" : "", a.logarithmicDepthBuffer ? "#define USE_LOGDEPTHBUF" : "", a.logarithmicDepthBuffer && e.get("EXT_frag_depth") ? "#define USE_LOGDEPTHBUF_EXT" : "", a.envMap && e.get("EXT_shader_texture_lod") ? "#define TEXTURE_LOD_EXT" : "", "uniform mat4 viewMatrix;", "uniform vec3 cameraPosition;", a.toneMapping !== Er ? "#define TONE_MAPPING" : "", a.toneMapping !== Er ? Xa.tonemapping_pars_fragment : "", a.toneMapping !== Er ? te("toneMapping", a.toneMapping) : "", a.dithering ? "#define DITHERING" : "", a.outputEncoding || a.mapEncoding || a.envMapEncoding || a.emissiveMapEncoding ? Xa.encodings_pars_fragment : "", a.mapEncoding ? Qt("mapTexelToLinear", a.mapEncoding) : "", a.envMapEncoding ? Qt("envMapTexelToLinear", a.envMapEncoding) : "", a.emissiveMapEncoding ? Qt("emissiveMapTexelToLinear", a.emissiveMapEncoding) : "", a.outputEncoding ? $t("linearToOutputTexel", a.outputEncoding) : "", a.depthPacking ? "#define DEPTH_PACKING " + i.depthPacking : "", "\n"].filter(re).join("\n")), l = ae(l = oe(l), a), c = ae(c = oe(c), a), i.isShaderMaterial || (l = se(l), c = se(c));
		var x = d + l,
			b = m + c,
			w = Jt(o, o.VERTEX_SHADER, x),
			M = Jt(o, o.FRAGMENT_SHADER, b);
		o.attachShader(y, w), o.attachShader(y, M), void 0 !== i.index0AttributeName ? o.bindAttribLocation(y, 0, i.index0AttributeName) : !0 === a.morphTargets && o.bindAttribLocation(y, 0, "position"), o.linkProgram(y);
		var S = o.getProgramInfoLog(y),
			G = o.getShaderInfoLog(w),
			E = o.getShaderInfoLog(M),
			T = !0,
			A = !0;
		!1 === o.getProgramParameter(y, o.LINK_STATUS) ? T = !1 : "" !== S || "" !== G && "" !== E || (A = !1), A && (this.diagnostics = {
			runnable: T,
			material: i,
			programLog: S,
			vertexShader: {
				log: G,
				prefix: d
			},
			fragmentShader: {
				log: E,
				prefix: m
			}
		}), o.deleteShader(w), o.deleteShader(M);
		var L;
		this.getUniforms = function() {
			return void 0 === L && (L = new X(o, y, t)), L
		};
		var C;
		return this.getAttributes = function() {
			return void 0 === C && (C = ie(o, y)), C
		}, this.destroy = function() {
			o.deleteProgram(y), this.program = void 0
		}, Object.defineProperties(this, {
			uniforms: {
				get: function() {
					return this.getUniforms()
				}
			},
			attributes: {
				get: function() {
					return this.getAttributes()
				}
			}
		}), this.id = Qa++, this.code = n, this.usedTimes = 1, this.program = y, this.vertexShader = w, this.fragmentShader = M, this
	}

	function ce(t, e, n) {
		function i(t) {
			var e = t.skeleton.bones;
			if(n.floatVertexTextures) return 1024;
			var i = n.maxVertexUniforms,
				r = Math.floor((i - 20) / 4),
				a = Math.min(r, e.length);
			return a < e.length ? 0 : a
		}

		function r(t, e) {
			var n;
			return t ? t.isTexture ? n = t.encoding : t.isWt && (n = t.texture.encoding) : n = Ga, n === Ga && e && (n = Ta), n
		}
		var a = [],
			o = {
				MeshDepthMaterial: "depth",
				MeshDistanceMaterial: "distanceRGBA",
				MeshNormalMaterial: "normal",
				Mal: "basic",
				MeshLambertMaterial: "lambert",
				MeshPhongMaterial: "phong",
				MeshToonMaterial: "phong",
				MeshStandardMaterial: "physical",
				MeshPhysicalMaterial: "physical",
				LineBasicMaterial: "basic",
				LineDashedMaterial: "dashed",
				PointsMaterial: "points",
				ShadowMaterial: "shadow"
			},
			s = ["precision", "supportsVertexTextures", "map", "mapEncoding", "envMap", "envMapMode", "envMapEncoding", "lightMap", "aoMap", "emissiveMap", "emissiveMapEncoding", "bumpMap", "normalMap", "displacementMap", "specularMap", "roughnessMap", "metalnessMap", "gradientMap", "alphaMap", "combine", "vertexColors", "fog", "useFog", "fogExp", "flatShading", "sizeAttenuation", "logarithmicDepthBuffer", "skinning", "maxBones", "useVertexTexture", "morphTargets", "morphNormals", "maxMorphTargets", "maxMorphNormals", "premultipliedAlpha", "numDirLights", "numPointLights", "numSpotLights", "numHemiLights", "numRectAreaLights", "shadowMapEnabled", "shadowMapType", "toneMapping", "physicallyCorrectLights", "alphaTest", "doubleSided", "flipSided", "numClippingPlanes", "numClipIntersection", "depthPacking", "dithering"];
		this.getParameters = function(e, a, s, l, c, h, u) {
			var f = o[e.type],
				p = u.isSkinnedMesh ? i(u) : 0,
				d = n.precision;
			null !== e.precision && (d = n.getMaxPrecision(e.precision), e.precision);
			var m = t.getRenderTarget();
			return {
				shaderID: f,
				precision: d,
				supportsVertexTextures: n.vertexTextures,
				outputEncoding: r(m ? m.texture : null, t.gammaOutput),
				map: !!e.map,
				mapEncoding: r(e.map, t.gammaInput),
				envMap: !!e.envMap,
				envMapMode: e.envMap && e.envMap.mapping,
				envMapEncoding: r(e.envMap, t.gammaInput),
				envMapCubeUV: !!e.envMap && (e.envMap.mapping === Dr || e.envMap.mapping === zr),
				lightMap: !!e.lightMap,
				aoMap: !!e.aoMap,
				emissiveMap: !!e.emissiveMap,
				emissiveMapEncoding: r(e.emissiveMap, t.gammaInput),
				bumpMap: !!e.bumpMap,
				normalMap: !!e.normalMap,
				displacementMap: !!e.displacementMap,
				roughnessMap: !!e.roughnessMap,
				metalnessMap: !!e.metalnessMap,
				specularMap: !!e.specularMap,
				alphaMap: !!e.alphaMap,
				gradientMap: !!e.gradientMap,
				combine: e.combine,
				vertexColors: e.vertexColors,
				fog: !!l,
				useFog: e.fog,
				fogExp: l,
				flatShading: e.flatShading,
				sizeAttenuation: e.sizeAttenuation,
				logarithmicDepthBuffer: n.logarithmicDepthBuffer,
				skinning: e.skinning && p > 0,
				maxBones: p,
				useVertexTexture: n.floatVertexTextures,
				morphTargets: e.morphTargets,
				morphNormals: e.morphNormals,
				maxMorphTargets: t.maxMorphTargets,
				maxMorphNormals: t.maxMorphNormals,
				numDirLights: a.directional.length,
				numPointLights: a.point.length,
				numSpotLights: a.spot.length,
				numRectAreaLights: a.rectArea.length,
				numHemiLights: a.hemi.length,
				numClippingPlanes: c,
				numClipIntersection: h,
				dithering: e.dithering,
				shadowMapEnabled: t.shadowMap.enabled && u.receiveShadow && s.length > 0,
				shadowMapType: t.shadowMap.type,
				toneMapping: t.toneMapping,
				physicallyCorrectLights: t.physicallyCorrectLights,
				premultipliedAlpha: e.premultipliedAlpha,
				alphaTest: e.alphaTest,
				doubleSided: e.side === Hi,
				flipSided: e.side === ji,
				depthPacking: void 0 !== e.depthPacking && e.depthPacking
			}
		}, this.getProgramCode = function(e, n) {
			var i = [];
			if(n.shaderID ? i.push(n.shaderID) : (i.push(e.fragmentShader), i.push(e.vertexShader)), void 0 !== e.defines)
				for(var r in e.defines) i.push(r), i.push(e.defines[r]);
			for(var a = 0; a < s.length; a++) i.push(n[s[a]]);
			return i.push(e.onBeforeCompile.toString()), i.push(t.gammaOutput), i.join()
		}, this.acquireProgram = function(n, i, r, o) {
			for(var s, l = 0, c = a.length; l < c; l++) {
				var h = a[l];
				if(h.code === o) {
					++(s = h).usedTimes;
					break
				}
			}
			return void 0 === s && (s = new le(t, e, o, n, i, r), a.push(s)), s
		}, this.releaseProgram = function(t) {
			if(0 == --t.usedTimes) {
				var e = a.indexOf(t);
				a[e] = a[a.length - 1], a.pop(), t.destroy()
			}
		}, this.programs = a
	}

	function he(t, e, n, i, r, a, o) {
		function s(t, e) {
			if(t.width > e || t.height > e) {
				var n = e / Math.max(t.width, t.height),
					i = document.createElementNS("http://www.w3.org/1999/xhtml", "canvas");
				return i.width = Math.floor(t.width * n), i.height = Math.floor(t.height * n), i.getContext("2d").drawImage(t, 0, 0, t.width, t.height, 0, 0, i.width, i.height), i
			}
			return t
		}

		function l(t) {
			return Oa.isPowerOfTwo(t.width) && Oa.isPowerOfTwo(t.height)
		}

		function c(t) {
			if(t instanceof HTMLImageElement || t instanceof HTMLCanvasElement || t instanceof ImageBitmap) {
				var e = document.createElementNS("http://www.w3.org/1999/xhtml", "canvas");
				return e.width = Oa.floorPowerOfTwo(t.width), e.height = Oa.floorPowerOfTwo(t.height), e.getContext("2d").drawImage(t, 0, 0, e.width, e.height), e
			}
			return t
		}

		function h(t) {
			return t.wrapS !== Fr || t.wrapT !== Fr || t.minFilter !== Br && t.minFilter !== Hr
		}

		function u(t, e) {
			return t.generateMipmaps && e && t.minFilter !== Br && t.minFilter !== Hr
		}

		function f(e) {
			return e === Br || e === Vr || e === jr ? t.NEAREST : t.LINEAR
		}

		function p(t) {
			var e = t.target;
			e.removeEventListener("dispose", p), m(e), o.textures--
		}

		function d(t) {
			var e = t.target;
			e.removeEventListener("dispose", d), g(e), o.textures--
		}

		function m(e) {
			var n = i.get(e);
			if(e.image && n.__image__webglTextureCube) console("del1"), t.deleteTexture(n.__image__webglTextureCube);
			else {
				if(console("del2"), void 0 === n.__webglInit) return;
				t.deleteTexture(n.__webglTexture)
			}
			i.remove(e)
		}

		function g(e) {
			var n = i.get(e),
				r = i.get(e.texture);
			if(e) {
				if(void 0 !== r.__webglTexture && t.deleteTexture(r.__webglTexture), e.depthTexture && e.depthTexture.dispose(), e.isWtCube)
					for(var a = 0; a < 6; a++) t.deleteFramebuffer(n.__webglFramebuffer[a]), n.__webglDepthbuffer && t.deleteRenderbuffer(n.__webglDepthbuffer[a]);
				else t.deleteFramebuffer(n.__webglFramebuffer), n.__webglDepthbuffer && t.deleteRenderbuffer(n.__webglDepthbuffer);
				i.remove(e.texture), i.remove(e)
			}
		}

		function v(e, r) {
			var a = i.get(e);
			if(e.version > 0 && a.__version !== e.version) {
				var o = e.image;
				if(void 0 === o);
				else if(!1 !== o.complete) return void y(a, e, r)
			}
			n.activeTexture(t.TEXTURE0 + r), n.bindTexture(t.TEXTURE_2D, a.__webglTexture)
		}

		function _(n, o, s) {
			var l;
			if(s ? (t.texParameteri(n, t.TEXTURE_WRAP_S, a.convert(o.wrapS)), t.texParameteri(n, t.TEXTURE_WRAP_T, a.convert(o.wrapT)), t.texParameteri(n, t.TEXTURE_MAG_FILTER, a.convert(o.magFilter)), t.texParameteri(n, t.TEXTURE_MIN_FILTER, a.convert(o.minFilter))) : (t.texParameteri(n, t.TEXTURE_WRAP_S, t.CLAMP_TO_EDGE), t.texParameteri(n, t.TEXTURE_WRAP_T, t.CLAMP_TO_EDGE), o.wrapS !== Fr || o.wrapT, t.texParameteri(n, t.TEXTURE_MAG_FILTER, f(o.magFilter)), t.texParameteri(n, t.TEXTURE_MIN_FILTER, f(o.minFilter)), o.minFilter !== Br && o.minFilter), l = e.get("EXT_texture_filter_anisotropic")) {
				if(o.type === $r && null === e.get("OES_texture_float_linear")) return;
				if(o.type === ta && null === e.get("OES_texture_half_float_linear")) return;
				(o.anisotropy > 1 || i.get(o).__currentAnisotropy) && (t.texParameterf(n, l.TEXTURE_MAX_ANISOTROPY_EXT, Math.min(o.anisotropy, r.getMaxAnisotropy())), i.get(o).__currentAnisotropy = o.anisotropy)
			}
		}

		function y(e, i, f) {
			void 0 === e.__webglInit && (e.__webglInit = !0, i.addEventListener("dispose", p), e.__webglTexture = t.createTexture(), o.textures++), n.activeTexture(t.TEXTURE0 + f), n.bindTexture(t.TEXTURE_2D, e.__webglTexture), t.pixelStorei(t.UNPACK_FLIP_Y_WEBGL, i.flipY), t.pixelStorei(t.UNPACK_PREMULTIPLY_ALPHA_WEBGL, i.premultiplyAlpha), t.pixelStorei(t.UNPACK_ALIGNMENT, i.unpackAlignment);
			var d = s(i.image, r.maxTextureSize);
			h(i) && !1 === l(d) && (d = c(d));
			var m = l(d),
				g = a.convert(i.format),
				v = a.convert(i.type);
			_(t.TEXTURE_2D, i, m);
			var y, x = i.mipmaps;
			if(i.isDepthTexture) {
				var b = t.DEPTH_COMPONENT;
				i.type === $r ? b = t.DEPTH_COMPONENT32F : S && (b = t.DEPTH_COMPONENT16), i.format === ua && b === t.DEPTH_COMPONENT && i.type !== Jr && i.type !== Qr && (i.type = Jr, v = a.convert(i.type)), i.format === fa && (b = t.DEPTH_STENCIL, i.type !== ra && (i.type = ra, v = a.convert(i.type))), n.texImage2D(t.TEXTURE_2D, 0, b, d.width, d.height, 0, g, v, null)
			} else if(i.isDataTexture)
				if(x.length > 0 && m) {
					for(var w = 0, M = x.length; w < M; w++) y = x[w], n.texImage2D(t.TEXTURE_2D, w, g, y.width, y.height, 0, g, v, y.data);
					i.generateMipmaps = !1
				} else n.texImage2D(t.TEXTURE_2D, 0, g, d.width, d.height, 0, g, v, d.data);
			else if(i.isCompressedTexture)
				for(var w = 0, M = x.length; w < M; w++) y = x[w], i.format !== sa && i.format !== oa ? n.getCompressedTextureFormats().indexOf(g) > -1 && n.compressedTexImage2D(t.TEXTURE_2D, w, g, y.width, y.height, 0, y.data) : n.texImage2D(t.TEXTURE_2D, w, g, y.width, y.height, 0, g, v, y.data);
			else if(x.length > 0 && m) {
				for(var w = 0, M = x.length; w < M; w++) y = x[w], n.texImage2D(t.TEXTURE_2D, w, g, g, v, y);
				i.generateMipmaps = !1
			} else n.texImage2D(t.TEXTURE_2D, 0, g, g, v, d);
			u(i, m) && t.generateMipmap(t.TEXTURE_2D), e.__version = i.version, i.onUpdate && i.onUpdate(i)
		}

		function x(e, r, o, s) {
			var l = a.convert(r.texture.format),
				c = a.convert(r.texture.type);
			n.texImage2D(s, 0, l, r.width, r.height, 0, l, c, null), t.bindFramebuffer(t.FRAMEBUFFER, e), t.framebufferTexture2D(t.FRAMEBUFFER, o, s, i.get(r.texture).__webglTexture, 0), t.bindFramebuffer(t.FRAMEBUFFER, null)
		}

		function b(e, n) {
			t.bindRenderbuffer(t.RENDERBUFFER, e), n.depthBuffer && !n.stencilBuffer ? (t.renderbufferStorage(t.RENDERBUFFER, t.DEPTH_COMPONENT16, n.width, n.height), t.framebufferRenderbuffer(t.FRAMEBUFFER, t.DEPTH_ATTACHMENT, t.RENDERBUFFER, e)) : n.depthBuffer && n.stencilBuffer ? (t.renderbufferStorage(t.RENDERBUFFER, t.DEPTH_STENCIL, n.width, n.height), t.framebufferRenderbuffer(t.FRAMEBUFFER, t.DEPTH_STENCIL_ATTACHMENT, t.RENDERBUFFER, e)) : t.renderbufferStorage(t.RENDERBUFFER, t.RGBA4, n.width, n.height), t.bindRenderbuffer(t.RENDERBUFFER, null)
		}

		function w(e, n) {
			n && n.isWtCube;
			t.bindFramebuffer(t.FRAMEBUFFER, e), i.get(n.depthTexture).__webglTexture && n.depthTexture.image.width === n.width && n.depthTexture.image.height === n.height || (n.depthTexture.image.width = n.width, n.depthTexture.image.height = n.height, n.depthTexture.needsUpdate = !0), v(n.depthTexture, 0);
			var r = i.get(n.depthTexture).__webglTexture;
			n.depthTexture.format === ua ? t.framebufferTexture2D(t.FRAMEBUFFER, t.DEPTH_ATTACHMENT, t.TEXTURE_2D, r, 0) : n.depthTexture.format === fa && t.framebufferTexture2D(t.FRAMEBUFFER, t.DEPTH_STENCIL_ATTACHMENT, t.TEXTURE_2D, r, 0)
		}

		function M(e) {
			var n = i.get(e),
				r = !0 === e.isWtCube;
			if(e.depthTexture) w(n.__webglFramebuffer, e);
			else if(r) {
				n.__webglDepthbuffer = [];
				for(var a = 0; a < 6; a++) t.bindFramebuffer(t.FRAMEBUFFER, n.__webglFramebuffer[a]), n.__webglDepthbuffer[a] = t.createRenderbuffer(), b(n.__webglDepthbuffer[a], e)
			} else t.bindFramebuffer(t.FRAMEBUFFER, n.__webglFramebuffer), n.__webglDepthbuffer = t.createRenderbuffer(), b(n.__webglDepthbuffer, e);
			t.bindFramebuffer(t.FRAMEBUFFER, null)
		}
		var S = "undefined" != typeof WebGL2RenderingContext && t instanceof window.WebGL2RenderingContext;
		this.setTexture2D = v, this.setTextureCube = function(e, c) {
			var h = i.get(e);
			if(6 === e.image.length)
				if(e.version > 0 && h.__version !== e.version) {
					h.__image__webglTextureCube || (e.addEventListener("dispose", p), h.__image__webglTextureCube = t.createTexture(), o.textures++), n.activeTexture(t.TEXTURE0 + c), n.bindTexture(t.TEXTURE_CUBE_MAP, h.__image__webglTextureCube), t.pixelStorei(t.UNPACK_FLIP_Y_WEBGL, e.flipY);
					for(var f = e && e.isCompressedTexture, d = e.image[0] && e.image[0].isDataTexture, m = [], g = 0; g < 6; g++) m[g] = f || d ? d ? e.image[g].image : e.image[g] : s(e.image[g], r.maxCubemapSize);
					var v = l(m[0]),
						y = a.convert(e.format),
						x = a.convert(e.type);
					for(_(t.TEXTURE_CUBE_MAP, e, v), g = 0; g < 6; g++)
						if(f)
							for(var b, w = m[g].mipmaps, M = 0, S = w.length; M < S; M++) b = w[M], e.format !== sa && e.format !== oa ? n.getCompressedTextureFormats().indexOf(y) > -1 && n.compressedTexImage2D(t.TEXTURE_CUBE_MAP_POSITIVE_X + g, M, y, b.width, b.height, 0, b.data) : n.texImage2D(t.TEXTURE_CUBE_MAP_POSITIVE_X + g, M, y, b.width, b.height, 0, y, x, b.data);
						else d ? n.texImage2D(t.TEXTURE_CUBE_MAP_POSITIVE_X + g, 0, y, m[g].width, m[g].height, 0, y, x, m[g].data) : n.texImage2D(t.TEXTURE_CUBE_MAP_POSITIVE_X + g, 0, y, y, x, m[g]);
					u(e, v) && t.generateMipmap(t.TEXTURE_CUBE_MAP), h.__version = e.version, e.onUpdate && e.onUpdate(e)
				} else n.activeTexture(t.TEXTURE0 + c), n.bindTexture(t.TEXTURE_CUBE_MAP, h.__image__webglTextureCube)
		}, this.setTextureCubeDynamic = function(e, r) {
			n.activeTexture(t.TEXTURE0 + r), n.bindTexture(t.TEXTURE_CUBE_MAP, i.get(e).__webglTexture)
		}, this.setupRenderTarget = function(e) {
			var r = i.get(e),
				a = i.get(e.texture);
			e.addEventListener("dispose", d), a.__webglTexture = t.createTexture(), o.textures++;
			var s = !0 === e.isWtCube,
				c = l(e);
			if(s)
				for(r.__webglFramebuffer = [], h = 0; h < 6; h++) r.__webglFramebuffer[h] = t.createFramebuffer();
			else r.__webglFramebuffer = t.createFramebuffer();
			if(s) {
				n.bindTexture(t.TEXTURE_CUBE_MAP, a.__webglTexture), _(t.TEXTURE_CUBE_MAP, e.texture, c);
				for(var h = 0; h < 6; h++) x(r.__webglFramebuffer[h], e, t.COLOR_ATTACHMENT0, t.TEXTURE_CUBE_MAP_POSITIVE_X + h);
				u(e.texture, c) && t.generateMipmap(t.TEXTURE_CUBE_MAP), n.bindTexture(t.TEXTURE_CUBE_MAP, null)
			} else n.bindTexture(t.TEXTURE_2D, a.__webglTexture), _(t.TEXTURE_2D, e.texture, c), x(r.__webglFramebuffer, e, t.COLOR_ATTACHMENT0, t.TEXTURE_2D), u(e.texture, c) && t.generateMipmap(t.TEXTURE_2D), n.bindTexture(t.TEXTURE_2D, null);
			e.depthBuffer && M(e)
		}, this.updateRenderTargetMipmap = function(e) {
			var r = e.texture;
			if(u(r, l(e))) {
				var a = e.isWtCube ? t.TEXTURE_CUBE_MAP : t.TEXTURE_2D,
					o = i.get(r).__webglTexture;
				n.bindTexture(a, o), t.generateMipmap(a), n.bindTexture(a, null)
			}
		}
	}

	function ue() {
		var t = {};
		return {
			get: function(e) {
				var n = e.uuid,
					i = t[n];
				return void 0 === i && (i = {}, t[n] = i), i
			},
			remove: function(e) {
				delete t[e.uuid]
			},
			clear: function() {
				t = {}
			}
		}
	}

	function fe(t, e, n) {
		function i(e, n, i) {
			var r = new Uint8Array(4),
				a = t.createTexture();
			t.bindTexture(e, a), t.texParameteri(e, t.TEXTURE_MIN_FILTER, t.NEAREST), t.texParameteri(e, t.TEXTURE_MAG_FILTER, t.NEAREST);
			for(var o = 0; o < i; o++) t.texImage2D(n + o, 0, t.RGBA, 1, 1, 0, t.RGBA, t.UNSIGNED_BYTE, r);
			return a
		}

		function r(e) {
			!0 !== y[e] && (t.enable(e), y[e] = !0)
		}

		function a(e) {
			!1 !== y[e] && (t.disable(e), y[e] = !1)
		}

		function o(e, i, o, s, l, c, h, u) {
			if(e !== Yi ? r(t.BLEND) : a(t.BLEND), e !== Qi) {
				if(e !== w || u !== L) switch(e) {
					case Zi:
						u ? (t.blendEquationSeparate(t.FUNC_ADD, t.FUNC_ADD), t.blendFuncSeparate(t.ONE, t.ONE, t.ONE, t.ONE)) : (t.blendEquation(t.FUNC_ADD), t.blendFunc(t.SRC_ALPHA, t.ONE));
						break;
					case Ji:
						u ? (t.blendEquationSeparate(t.FUNC_ADD, t.FUNC_ADD), t.blendFuncSeparate(t.ZERO, t.ZERO, t.ONE_MINUS_SRC_COLOR, t.ONE_MINUS_SRC_ALPHA)) : (t.blendEquation(t.FUNC_ADD), t.blendFunc(t.ZERO, t.ONE_MINUS_SRC_COLOR));
						break;
					case Ki:
						u ? (t.blendEquationSeparate(t.FUNC_ADD, t.FUNC_ADD), t.blendFuncSeparate(t.ZERO, t.SRC_COLOR, t.ZERO, t.SRC_ALPHA)) : (t.blendEquation(t.FUNC_ADD), t.blendFunc(t.ZERO, t.SRC_COLOR));
						break;
					default:
						u ? (t.blendEquationSeparate(t.FUNC_ADD, t.FUNC_ADD), t.blendFuncSeparate(t.ONE, t.ONE_MINUS_SRC_ALPHA, t.ONE, t.ONE_MINUS_SRC_ALPHA)) : (t.blendEquationSeparate(t.FUNC_ADD, t.FUNC_ADD), t.blendFuncSeparate(t.SRC_ALPHA, t.ONE_MINUS_SRC_ALPHA, t.ONE, t.ONE_MINUS_SRC_ALPHA))
				}
				M = null, S = null, G = null, E = null, T = null, A = null
			} else l = l || i, c = c || o, h = h || s, i === M && l === E || (t.blendEquationSeparate(n.convert(i), n.convert(l)), M = i, E = l), o === S && s === G && c === T && h === A || (t.blendFuncSeparate(n.convert(o), n.convert(s), n.convert(c), n.convert(h)), S = o, G = s, T = c, A = h);
			w = e, L = u
		}

		function s(e) {
			C !== e && (e ? t.frontFace(t.CW) : t.frontFace(t.CCW), C = e)
		}

		function c(e) {
			e !== Di ? (r(t.CULL_FACE), e !== P && (e === zi ? t.cullFace(t.BACK) : e === Ui ? t.cullFace(t.FRONT) : t.cullFace(t.FRONT_AND_BACK))) : a(t.CULL_FACE), P = e
		}

		function h(e, n, i) {
			e ? (r(t.POLYGON_OFFSET_FILL), R === n && O === i || (t.polygonOffset(n, i), R = n, O = i)) : a(t.POLYGON_OFFSET_FILL)
		}

		function u(e) {
			void 0 === e && (e = t.TEXTURE0 + N - 1), U !== e && (t.activeTexture(e), U = e)
		}
		var f = new function() {
				var e = !1,
					n = new l,
					i = null,
					r = new l(0, 0, 0, 0);
				return {
					setMask: function(n) {
						i === n || e || (t.colorMask(n, n, n, n), i = n)
					},
					setLocked: function(t) {
						e = t
					},
					setClear: function(e, i, a, o, s) {
						!0 === s && (e *= o, i *= o, a *= o), n.set(e, i, a, o), !1 === r.equals(n) && (t.clearColor(e, i, a, o), r.copy(n))
					},
					reset: function() {
						e = !1, i = null, r.set(-1, 0, 0, 0)
					}
				}
			},
			p = new function() {
				var e = !1,
					n = null,
					i = null,
					o = null;
				return {
					setTest: function(e) {
						e ? r(t.DEPTH_TEST) : a(t.DEPTH_TEST)
					},
					setMask: function(i) {
						n === i || e || (t.depthMask(i), n = i)
					},
					setFunc: function(e) {
						if(i !== e) {
							if(e) switch(e) {
								case mr:
									t.depthFunc(t.NEVER);
									break;
								case gr:
									t.depthFunc(t.ALWAYS);
									break;
								case vr:
									t.depthFunc(t.LESS);
									break;
								case _r:
									t.depthFunc(t.LEQUAL);
									break;
								case yr:
									t.depthFunc(t.EQUAL);
									break;
								case xr:
									t.depthFunc(t.GEQUAL);
									break;
								case br:
									t.depthFunc(t.GREATER);
									break;
								case wr:
									t.depthFunc(t.NOTEQUAL);
									break;
								default:
									t.depthFunc(t.LEQUAL)
							} else t.depthFunc(t.LEQUAL);
							i = e
						}
					},
					setLocked: function(t) {
						e = t
					},
					setClear: function(e) {
						o !== e && (t.clearDepth(e), o = e)
					},
					reset: function() {
						e = !1, n = null, i = null, o = null
					}
				}
			},
			d = new function() {
				var e = !1,
					n = null,
					i = null,
					o = null,
					s = null,
					l = null,
					c = null,
					h = null,
					u = null;
				return {
					setTest: function(e) {
						e ? r(t.STENCIL_TEST) : a(t.STENCIL_TEST)
					},
					setMask: function(i) {
						n === i || e || (t.stencilMask(i), n = i)
					},
					setFunc: function(e, n, r) {
						i === e && o === n && s === r || (t.stencilFunc(e, n, r), i = e, o = n, s = r)
					},
					setOp: function(e, n, i) {
						l === e && c === n && h === i || (t.stencilOp(e, n, i), l = e, c = n, h = i)
					},
					setLocked: function(t) {
						e = t
					},
					setClear: function(e) {
						u !== e && (t.clearStencil(e), u = e)
					},
					reset: function() {
						e = !1, n = null, i = null, o = null, s = null, l = null, c = null, h = null, u = null
					}
				}
			},
			m = t.getParameter(t.MAX_VERTEX_ATTRIBS),
			g = new Uint8Array(m),
			v = new Uint8Array(m),
			_ = new Uint8Array(m),
			y = {},
			x = null,
			b = null,
			w = null,
			M = null,
			S = null,
			G = null,
			E = null,
			T = null,
			A = null,
			L = !1,
			C = null,
			P = null,
			I = null,
			R = null,
			O = null,
			N = t.getParameter(t.MAX_COMBINED_TEXTURE_IMAGE_UNITS),
			D = parseFloat(/^WebGL\ ([0-9])/.exec(t.getParameter(t.VERSION))[1]),
			z = parseFloat(D) >= 1,
			U = null,
			F = {},
			k = new l,
			B = new l,
			V = {};
		return V[t.TEXTURE_2D] = i(t.TEXTURE_2D, t.TEXTURE_2D, 1), V[t.TEXTURE_CUBE_MAP] = i(t.TEXTURE_CUBE_MAP, t.TEXTURE_CUBE_MAP_POSITIVE_X, 6), f.setClear(0, 0, 0, 1), p.setClear(1), d.setClear(0), r(t.DEPTH_TEST), p.setFunc(_r), s(!1), c(zi), r(t.CULL_FACE), r(t.BLEND), o(qi), {
			buffers: {
				color: f,
				depth: p,
				stencil: d
			},
			initAttributes: function() {
				for(var t = 0, e = g.length; t < e; t++) g[t] = 0
			},
			enableAttribute: function(n) {
				g[n] = 1, 0 === v[n] && (t.enableVertexAttribArray(n), v[n] = 1), 0 !== _[n] && (e.get("ANGLE_instanced_arrays").vertexAttribDivisorANGLE(n, 0), _[n] = 0)
			},
			enableAttributeAndDivisor: function(n, i) {
				g[n] = 1, 0 === v[n] && (t.enableVertexAttribArray(n), v[n] = 1), _[n] !== i && (e.get("ANGLE_instanced_arrays").vertexAttribDivisorANGLE(n, i), _[n] = i)
			},
			disableUnusedAttributes: function() {
				for(var e = 0, n = v.length; e !== n; ++e) v[e] !== g[e] && (t.disableVertexAttribArray(e), v[e] = 0)
			},
			enable: r,
			disable: a,
			getCompressedTextureFormats: function() {
				if(null === x && (x = [], e.get("WEBGL_compressed_texture_pvrtc") || e.get("WEBGL_compressed_texture_s3tc") || e.get("WEBGL_compressed_texture_etc1")))
					for(var n = t.getParameter(t.COMPRESSED_TEXTURE_FORMATS), i = 0; i < n.length; i++) x.push(n[i]);
				return x
			},
			useProgram: function(e) {
				return b !== e && (t.useProgram(e), b = e, !0)
			},
			setBlending: o,
			setMaterial: function(e) {
				e.side === Hi ? a(t.CULL_FACE) : r(t.CULL_FACE), s(e.side === ji), !0 === e.transparent ? o(e.blending, e.blendEquation, e.blendSrc, e.blendDst, e.blendEquationAlpha, e.blendSrcAlpha, e.blendDstAlpha, e.premultipliedAlpha) : o(Yi), p.setFunc(e.depthFunc), p.setTest(e.depthTest), p.setMask(e.depthWrite), f.setMask(e.colorWrite), h(e.polygonOffset, e.polygonOffsetFactor, e.polygonOffsetUnits)
			},
			setFlipSided: s,
			setCullFace: c,
			setLineWidth: function(e) {
				e !== I && (z && t.lineWidth(e), I = e)
			},
			setPolygonOffset: h,
			setScissorTest: function(e) {
				e ? r(t.SCISSOR_TEST) : a(t.SCISSOR_TEST)
			},
			activeTexture: u,
			bindTexture: function(e, n) {
				null === U && u();
				var i = F[U];
				void 0 === i && (i = {
					type: void 0,
					texture: void 0
				}, F[U] = i), i.type === e && i.texture === n || (t.bindTexture(e, n || V[e]), i.type = e, i.texture = n)
			},
			compressedTexImage2D: function() {
				try {
					t.compressedTexImage2D.apply(t, arguments)
				} catch(t) {}
			},
			texImage2D: function() {
				try {
					t.texImage2D.apply(t, arguments)
				} catch(t) {}
			},
			scissor: function(e) {
				!1 === k.equals(e) && (t.scissor(e.x, e.y, e.z, e.w), k.copy(e))
			},
			viewport: function(e) {
				!1 === B.equals(e) && (t.viewport(e.x, e.y, e.z, e.w), B.copy(e))
			},
			reset: function() {
				for(var e = 0; e < v.length; e++) 1 === v[e] && (t.disableVertexAttribArray(e), v[e] = 0);
				y = {}, x = null, U = null, F = {}, b = null, w = null, C = null, P = null, f.reset(), p.reset(), d.reset()
			}
		}
	}

	function pe(t, e, n) {
		function i(e) {
			if("highp" === e) {
				if(t.getShaderPrecisionFormat(t.VERTEX_SHADER, t.HIGH_FLOAT).precision > 0 && t.getShaderPrecisionFormat(t.FRAGMENT_SHADER, t.HIGH_FLOAT).precision > 0) return "highp";
				e = "mediump"
			}
			return "mediump" === e && t.getShaderPrecisionFormat(t.VERTEX_SHADER, t.MEDIUM_FLOAT).precision > 0 && t.getShaderPrecisionFormat(t.FRAGMENT_SHADER, t.MEDIUM_FLOAT).precision > 0 ? "mediump" : "lowp"
		}
		var r, a = void 0 !== n.precision ? n.precision : "highp",
			o = i(a);
		o !== a && (a = o);
		var s = !0 === n.logarithmicDepthBuffer,
			l = t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS),
			c = t.getParameter(t.MAX_VERTEX_TEXTURE_IMAGE_UNITS),
			h = t.getParameter(t.MAX_TEXTURE_SIZE),
			u = t.getParameter(t.MAX_CUBE_MAP_TEXTURE_SIZE),
			f = t.getParameter(t.MAX_VERTEX_ATTRIBS),
			p = t.getParameter(t.MAX_VERTEX_UNIFORM_VECTORS),
			d = t.getParameter(t.MAX_VARYING_VECTORS),
			m = t.getParameter(t.MAX_FRAGMENT_UNIFORM_VECTORS),
			g = c > 0,
			v = !!e.get("OES_texture_float");
		return {
			getMaxAnisotropy: function() {
				if(void 0 !== r) return r;
				var n = e.get("EXT_texture_filter_anisotropic");
				return r = null !== n ? t.getParameter(n.MAX_TEXTURE_MAX_ANISOTROPY_EXT) : 0
			},
			getMaxPrecision: i,
			precision: a,
			logarithmicDepthBuffer: s,
			maxTextures: l,
			maxVertexTextures: c,
			maxTextureSize: h,
			maxCubemapSize: u,
			maxAttributes: f,
			maxVertexUniforms: p,
			maxVaryings: d,
			maxFragmentUniforms: m,
			vertexTextures: g,
			floatFragmentTextures: v,
			floatVertexTextures: g && v
		}
	}

	function de(t, e, n, i) {
		ht.call(this), this.type = "Pa", this.fov = void 0 !== t ? t : 50, this.zoom = 1, this.near = void 0 !== n ? n : .1, this.far = void 0 !== i ? i : 2e3, this.focus = 10, this.aspect = void 0 !== e ? e : 1, this.view = null, this.filmGauge = 35, this.filmOffset = 0, this.ux()
	}

	function me(t) {
		de.call(this), this.cameras = t || []
	}

	function ge(t) {
		var e = {};
		return {
			get: function(n) {
				if(void 0 !== e[n]) return e[n];
				var i;
				switch(n) {
					case "WEBGL_depth_texture":
						i = t.getExtension("WEBGL_depth_texture") || t.getExtension("MOZ_WEBGL_depth_texture") || t.getExtension("WEBKIT_WEBGL_depth_texture");
						break;
					case "EXT_texture_filter_anisotropic":
						i = t.getExtension("EXT_texture_filter_anisotropic") || t.getExtension("MOZ_EXT_texture_filter_anisotropic") || t.getExtension("WEBKIT_EXT_texture_filter_anisotropic");
						break;
					case "WEBGL_compressed_texture_s3tc":
						i = t.getExtension("WEBGL_compressed_texture_s3tc") || t.getExtension("MOZ_WEBGL_compressed_texture_s3tc") || t.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");
						break;
					case "WEBGL_compressed_texture_pvrtc":
						i = t.getExtension("WEBGL_compressed_texture_pvrtc") || t.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");
						break;
					case "WEBGL_compressed_texture_etc1":
						i = t.getExtension("WEBGL_compressed_texture_etc1");
						break;
					default:
						i = t.getExtension(n)
				}
				return e[n] = i, i
			}
		}
	}

	function ve() {
		function t() {
			h.value !== i && (h.value = i, h.needsUpdate = r > 0), n.numPlanes = r, n.numIntersection = 0
		}

		function e(t, e, i, r) {
			var a = null !== t ? t.length : 0,
				o = null;
			if(0 !== a) {
				if(o = h.value, !0 !== r || null === o) {
					var s = i + 4 * a,
						u = e.matrixWorldInverse;
					c.getNormalMatrix(u), (null === o || o.length < s) && (o = new Float32Array(s));
					for(var f = 0, p = i; f !== a; ++f, p += 4) l.copy(t[f]).applyMatrix4(u, c), l.normal.toArray(o, p), o[p + 3] = l.constant
				}
				h.value = o, h.needsUpdate = !0
			}
			return n.numPlanes = a, o
		}
		var n = this,
			i = null,
			r = 0,
			a = !1,
			s = !1,
			l = new it,
			c = new o,
			h = {
				value: null,
				needsUpdate: !1
			};
		this.uniform = h, this.numPlanes = 0, this.numIntersection = 0, this.init = function(t, n, o) {
			var s = 0 !== t.length || n || 0 !== r || a;
			return a = n, i = e(t, o, 0), r = t.length, s
		}, this.beginShadows = function() {
			s = !0, e(null)
		}, this.endShadows = function() {
			s = !1, t()
		}, this.setState = function(n, o, l, c, u, f) {
			if(!a || null === n || 0 === n.length || s && !l) s ? e(null) : t();
			else {
				var p = s ? 0 : r,
					d = 4 * p,
					m = u.clippingState || null;
				h.value = m, m = e(n, c, d, f);
				for(var g = 0; g !== d; ++g) m[g] = i[g];
				u.clippingState = m, this.numIntersection = o ? this.numPlanes : 0, this.numPlanes += p
			}
		}
	}

	function _e(t, e) {
		return {
			convert: function(n) {
				var i;
				if(n === Ur) return t.REPEAT;
				if(n === Fr) return t.CLAMP_TO_EDGE;
				if(n === kr) return t.MIRRORED_REPEAT;
				if(n === Br) return t.NEAREST;
				if(n === Vr) return t.NEAREST_MIPMAP_NEAREST;
				if(n === jr) return t.NEAREST_MIPMAP_LINEAR;
				if(n === Hr) return t.LINEAR;
				if(n === Wr) return t.LINEAR_MIPMAP_NEAREST;
				if(n === Xr) return t.LINEAR_MIPMAP_LINEAR;
				if(n === Yr) return t.UNSIGNED_BYTE;
				if(n === ea) return t.UNSIGNED_SHORT_4_4_4_4;
				if(n === na) return t.UNSIGNED_SHORT_5_5_5_1;
				if(n === ia) return t.UNSIGNED_SHORT_5_6_5;
				if(n === qr) return t.BYTE;
				if(n === Zr) return t.SHORT;
				if(n === Jr) return t.UNSIGNED_SHORT;
				if(n === Kr) return t.INT;
				if(n === Qr) return t.UNSIGNED_INT;
				if(n === $r) return t.FLOAT;
				if(n === ta && null !== (i = e.get("OES_texture_half_float"))) return i.HALF_FLOAT_OES;
				if(n === aa) return t.ALPHA;
				if(n === oa) return t.RGB;
				if(n === sa) return t.RGBA;
				if(n === la) return t.LUMINANCE;
				if(n === ca) return t.LUMINANCE_ALPHA;
				if(n === ua) return t.DEPTH_COMPONENT;
				if(n === fa) return t.DEPTH_STENCIL;
				if(n === $i) return t.FUNC_ADD;
				if(n === tr) return t.FUNC_SUBTRACT;
				if(n === er) return t.FUNC_REVERSE_SUBTRACT;
				if(n === rr) return t.ZERO;
				if(n === ar) return t.ONE;
				if(n === or) return t.SRC_COLOR;
				if(n === sr) return t.ONE_MINUS_SRC_COLOR;
				if(n === lr) return t.SRC_ALPHA;
				if(n === cr) return t.ONE_MINUS_SRC_ALPHA;
				if(n === hr) return t.DST_ALPHA;
				if(n === ur) return t.ONE_MINUS_DST_ALPHA;
				if(n === fr) return t.DST_COLOR;
				if(n === pr) return t.ONE_MINUS_DST_COLOR;
				if(n === dr) return t.SRC_ALPHA_SATURATE;
				if((n === pa || n === da || n === ma || n === ga) && null !== (i = e.get("WEBGL_compressed_texture_s3tc"))) {
					if(n === pa) return i.COMPRESSED_RGB_S3TC_DXT1_EXT;
					if(n === da) return i.COMPRESSED_RGBA_S3TC_DXT1_EXT;
					if(n === ma) return i.COMPRESSED_RGBA_S3TC_DXT3_EXT;
					if(n === ga) return i.COMPRESSED_RGBA_S3TC_DXT5_EXT
				}
				if((n === va || n === _a || n === ya || n === xa) && null !== (i = e.get("WEBGL_compressed_texture_pvrtc"))) {
					if(n === va) return i.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;
					if(n === _a) return i.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;
					if(n === ya) return i.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;
					if(n === xa) return i.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG
				}
				if(n === ba && null !== (i = e.get("WEBGL_compressed_texture_etc1"))) return i.COMPRESSED_RGB_ETC1_WEBGL;
				if((n === nr || n === ir) && null !== (i = e.get("EXT_blend_minmax"))) {
					if(n === nr) return i.MIN_EXT;
					if(n === ir) return i.MAX_EXT
				}
				return n === ra && null !== (i = e.get("WEBGL_depth_texture")) ? i.UNSIGNED_INT_24_8_WEBGL : 0
			}
		}
	}

	function ye(t) {
		function e() {
			return null === Q ? pt : 1
		}

		function n() {
			(Tt = new ge(Gt)).get("WEBGL_depth_texture"), Tt.get("OES_texture_float"), Tt.get("OES_texture_float_linear"), Tt.get("OES_texture_half_float"), Tt.get("OES_texture_half_float_linear"), Tt.get("OES_standard_derivatives"), Tt.get("OES_element_index_uint"), Tt.get("ANGLE_instanced_arrays"), Qt = new _e(Gt, Tt), At = new pe(Gt, Tt, t), (Lt = new fe(Gt, Tt, Qt)).scissor(lt.copy(mt).multiplyScalar(pt)), Lt.viewport(st.copy(dt).multiplyScalar(pt)), Ct = new ue, Pt = new he(Gt, Tt, Lt, Ct, At, Qt, Mt), It = new ot(Gt), Rt = new Xt(Gt, It, Mt), Ot = new Zt(Rt, St), kt = new jt(Gt), Dt = new ce(q, Tt, At), Nt = new qt, Ut = new Bt, Ft = new zt(q, Lt, Rt, k), Vt = new Wt(Gt, Tt, St), Yt = new Ht(Gt, Tt, St), Jt = new Z(q, Gt, Lt, Pt, At), Kt = new K(q, Gt, Lt, Pt, At), q.info.programs = Dt.programs, q.context = Gt, q.capabilities = At, q.extensions = Tt, q.properties = Ct, q.renderLists = Ut, q.state = Lt
		}

		function r(t) {
			t.preventDefault(), J = !0
		}

		function o() {
			J = !1, n()
		}

		function s(t) {
			var e = t.target;
			e.removeEventListener("dispose", s), c(e)
		}

		function c(t) {
			h(t), Ct.remove(t)
		}

		function h(t) {
			var e = Ct.get(t).program;
			t.program = void 0, void 0 !== e && Dt.releaseProgram(e)
		}

		function f(t, e, n, i) {
			if(!n || !n.isInstancedBufferGeometry || null !== Tt.get("ANGLE_instanced_arrays")) {
				void 0 === i && (i = 0), Lt.initAttributes();
				var r = n.attributes,
					a = e.getAttributes(),
					o = t.defaultAttributeValues;
				for(var s in a) {
					var l = a[s];
					if(l >= 0) {
						var c = r[s];
						if(void 0 !== c) {
							var h = c.normalized,
								u = c.itemSize,
								f = It.get(c);
							if(void 0 === f) continue;
							var p = f.buffer,
								d = f.type,
								m = f.bytesPerElement;
							if(c.isInterleavedBufferAttribute) {
								var g = c.data,
									v = g.stride,
									_ = c.offset;
								g && g.isInstancedInterleavedBuffer ? (Lt.enableAttributeAndDivisor(l, g.meshPerAttribute), void 0 === n.maxInstancedCount && (n.maxInstancedCount = g.meshPerAttribute * g.count)) : Lt.enableAttribute(l), Gt.bindBuffer(Gt.ARRAY_BUFFER, p), Gt.vertexAttribPointer(l, u, d, h, v * m, (i * v + _) * m)
							} else c.isInstancedBufferAttribute ? (Lt.enableAttributeAndDivisor(l, c.meshPerAttribute), void 0 === n.maxInstancedCount && (n.maxInstancedCount = c.meshPerAttribute * c.count)) : Lt.enableAttribute(l), Gt.bindBuffer(Gt.ARRAY_BUFFER, p), Gt.vertexAttribPointer(l, u, d, h, 0, i * u * m)
						} else if(void 0 !== o) {
							var y = o[s];
							if(void 0 !== y) switch(y.length) {
								case 2:
									Gt.vertexAttrib2fv(l, y);
									break;
								case 3:
									Gt.vertexAttrib3fv(l, y);
									break;
								case 4:
									Gt.vertexAttrib4fv(l, y);
									break;
								default:
									Gt.vertexAttrib1fv(l, y)
							}
						}
					}
				}
				Lt.disableUnusedAttributes()
			}
		}

		function p() {
			te || (window.requestAnimationFrame(d), te = !0)
		}

		function d(t) {
			null !== ee && ee(t), window.requestAnimationFrame(d)
		}

		function m(t, e, n) {
			if(!1 !== t.visible) {
				if(t.layers.test(e.layers))
					if(t.isLight) V.push(t), t.castShadow && j.push(t);
					else if(t.isSprite) t.frustumCulled && !vt.intersectsSprite(t) || W.push(t);
				else if(t.isLensFlare) Y.push(t);
				else if((t.isMesh || t.isLine || t.isPoints) && (t.isSkinnedMesh && t.skeleton.update(), !t.frustumCulled || vt.intersectsObject(t))) {
					n && wt.setFromMatrixPosition(t.matrixWorld).applyMatrix4(bt);
					var i = Ot.update(t),
						r = t.material;
					if(Array.isArray(r))
						for(var a = i.groups, o = 0, s = a.length; o < s; o++) {
							var l = a[o],
								c = r[l.materialIndex];
							c && c.visible && H.push(t, i, c, wt.z, l)
						} else r.visible && H.push(t, i, r, wt.z, null)
				}
				for(var h = t.children, o = 0, s = h.length; o < s; o++) m(h[o], e, n)
			}
		}

		function g(t, e, n, i) {
			for(var r = 0, a = t.length; r < a; r++) {
				var o = t[r],
					s = o.object,
					l = o.geometry,
					c = void 0 === i ? o.material : i,
					h = o.group;
				if(n.isArrayCamera) {
					it = n;
					for(var u = n.cameras, f = 0, p = u.length; f < p; f++) {
						var d = u[f];
						if(s.layers.test(d.layers)) {
							var m = d.bounds,
								g = m.x * ut,
								_ = m.y * ft,
								y = m.z * ut,
								x = m.w * ft;
							Lt.viewport(st.set(g, _, y, x).multiplyScalar(pt)), v(s, e, d, l, c, h)
						}
					}
				} else it = null, v(s, e, n, l, c, h)
			}
		}

		function v(t, e, n, i, r, a) {
			t.onBeforeRender(q, e, n, i, r, a), t.modelViewMatrix.multiplyMatrices(n.matrixWorldInverse, t.matrixWorld), t.normalMatrix.getNormalMatrix(t.modelViewMatrix), q.renderBufferDirect(n, e.fog, i, r, t, a), t.onAfterRender(q, e, n, i, r, a)
		}

		function _(t, e, n) {
			var i = Ct.get(t),
				r = Dt.getParameters(t, Nt.state, j, e, _t.numPlanes, _t.numIntersection, n),
				a = Dt.getProgramCode(t, r),
				o = i.program,
				l = !0;
			if(void 0 === o) t.addEventListener("dispose", s);
			else if(o.code !== a) h(t);
			else {
				if(void 0 !== r.shaderID) return;
				l = !1
			}
			if(l) {
				if(r.shaderID) {
					var c = Ya[r.shaderID];
					i.shader = {
						name: t.type,
						uniforms: Wa.clone(c.uniforms),
						vertexShader: c.vertexShader,
						fragmentShader: c.fragmentShader
					}
				} else i.shader = {
					name: t.type,
					uniforms: t.uniforms,
					vertexShader: t.vertexShader,
					fragmentShader: t.fragmentShader
				};
				t.onBeforeCompile(i.shader), o = Dt.acquireProgram(t, i.shader, r, a), i.program = o, t.program = o
			}
			var u = o.getAttributes();
			if(t.morphTargets) {
				t.numSupportedMorphTargets = 0;
				for(f = 0; f < q.maxMorphTargets; f++) u["morphTarget" + f] >= 0 && t.numSupportedMorphTargets++
			}
			if(t.morphNormals) {
				t.numSupportedMorphNormals = 0;
				for(var f = 0; f < q.maxMorphNormals; f++) u["morphNormal" + f] >= 0 && t.numSupportedMorphNormals++
			}
			var p = i.shader.uniforms;
			(t.isShaderMaterial || t.isRawShaderMaterial) && !0 !== t.clipping || (i.numClippingPlanes = _t.numPlanes, i.numIntersection = _t.numIntersection, p.cs = _t.uniform), i.fog = e, i.lightsHash = Nt.state.hash, t.lights && (p.ambientLightColor.value = Nt.state.ambient, p.directionalLights.value = Nt.state.directional, p.spotLights.value = Nt.state.spot, p.rectAreaLights.value = Nt.state.rectArea, p.pointLights.value = Nt.state.point, p.hemisphereLights.value = Nt.state.hemi, p.directionalShadowMap.value = Nt.state.directionalShadowMap, p.directionalShadowMatrix.value = Nt.state.directionalShadowMatrix, p.spotShadowMap.value = Nt.state.spotShadowMap, p.spotShadowMatrix.value = Nt.state.spotShadowMatrix, p.pointShadowMap.value = Nt.state.pointShadowMap, p.pointShadowMatrix.value = Nt.state.pointShadowMatrix);
			var d = i.program.getUniforms(),
				m = X.seqWithValue(d.seq, p);
			i.uniformsList = m
		}

		function y(t, e, n, i) {
			ht = 0;
			var r = Ct.get(n);
			if(yt && (xt || t !== nt)) {
				var a = t === nt && n.id === tt;
				_t.setState(n.cs, n.clipIntersection, n.clipShadows, t, r, a)
			}!1 === n.needsUpdate && (void 0 === r.program ? n.needsUpdate = !0 : n.fog && r.fog !== e ? n.needsUpdate = !0 : n.lights && r.lightsHash !== Nt.state.hash ? n.needsUpdate = !0 : void 0 === r.numClippingPlanes || r.numClippingPlanes === _t.numPlanes && r.numIntersection === _t.numIntersection || (n.needsUpdate = !0)), n.needsUpdate && (_(n, e, i), n.needsUpdate = !1);
			var o = !1,
				s = !1,
				l = !1,
				c = r.program,
				h = c.getUniforms(),
				f = r.shader.uniforms;
			if(Lt.useProgram(c.program) && (o = !0, s = !0, l = !0), n.id !== tt && (tt = n.id, s = !0), o || t !== nt) {
				if(h.setValue(Gt, "projectionMatrix", t.projectionMatrix), At.logarithmicDepthBuffer && h.setValue(Gt, "logDepthBufFC", 2 / (Math.log(t.far + 1) / Math.LN2)), nt !== (it || t) && (nt = it || t, s = !0, l = !0), n.isShaderMaterial || n.isMeshPhongMaterial || n.isMeshStandardMaterial || n.envMap) {
					var p = h.map.cameraPosition;
					void 0 !== p && p.setValue(Gt, wt.setFromMatrixPosition(t.matrixWorld))
				}(n.isMeshPhongMaterial || n.isMeshLambertMaterial || n.isMal || n.isMeshStandardMaterial || n.isShaderMaterial || n.skinning) && h.setValue(Gt, "viewMatrix", t.matrixWorldInverse)
			}
			if(n.skinning) {
				h.setOptional(Gt, i, "bindMatrix"), h.setOptional(Gt, i, "bindMatrixInverse");
				var d = i.skeleton;
				if(d) {
					var m = d.bones;
					if(At.floatVertexTextures) {
						if(void 0 === d.boneTexture) {
							var g = Math.sqrt(4 * m.length);
							g = Oa.ceilPowerOfTwo(g), g = Math.max(g, 4);
							var v = new Float32Array(g * g * 4);
							v.set(d.boneMatrices);
							var y = new u(v, g, g, sa, $r);
							d.boneMatrices = v, d.boneTexture = y, d.boneTextureSize = g
						}
						h.setValue(Gt, "boneTexture", d.boneTexture), h.setValue(Gt, "boneTextureSize", d.boneTextureSize)
					} else h.setOptional(Gt, d, "boneMatrices")
				}
			}
			return s && (h.setValue(Gt, "toneMappingExposure", q.toneMappingExposure), h.setValue(Gt, "toneMappingWhitePoint", q.toneMappingWhitePoint), n.lights && R(f, l), e && n.fog && S(f, e), n.isMal ? x(f, n) : n.isMeshLambertMaterial ? (x(f, n), G(f, n)) : n.isMeshPhongMaterial ? (x(f, n), n.isMeshToonMaterial ? T(f, n) : E(f, n)) : n.isMeshStandardMaterial ? (x(f, n), n.isMeshPhysicalMaterial ? L(f, n) : A(f, n)) : n.isMeshDepthMaterial ? (x(f, n), C(f, n)) : n.isMeshDistanceMaterial ? (x(f, n), P(f, n)) : n.isMeshNormalMaterial ? (x(f, n), I(f, n)) : n.isLineBasicMaterial ? (b(f, n), n.isLineDashedMaterial && w(f, n)) : n.isPointsMaterial ? M(f, n) : n.isShadowMaterial && (f.color.value = n.color, f.opacity.value = n.opacity), void 0 !== f.ltcMat && (f.ltcMat.value = Ha.LTC_MAT_TEXTURE), void 0 !== f.ltcMag && (f.ltcMag.value = Ha.LTC_MAG_TEXTURE), X.upload(Gt, r.uniformsList, f, q)), h.setValue(Gt, "modelViewMatrix", i.modelViewMatrix), h.setValue(Gt, "normalMatrix", i.normalMatrix), h.setValue(Gt, "modelMatrix", i.matrixWorld), c
		}

		function x(t, e) {
			t.opacity.value = e.opacity, e.color && (t.diffuse.value = e.color), e.emissive && t.emissive.value.copy(e.emissive).multiplyScalar(e.emissiveIntensity), e.map && (t.map.value = e.map), e.alphaMap && (t.alphaMap.value = e.alphaMap), e.specularMap && (t.specularMap.value = e.specularMap), e.envMap && (t.envMap.value = e.envMap, t.flipEnvMap.value = e.envMap && e.envMap.isCubeTexture ? -1 : 1, t.reflectivity.value = e.reflectivity, t.refractionRatio.value = e.refractionRatio), e.lightMap && (t.lightMap.value = e.lightMap, t.lightMapIntensity.value = e.lightMapIntensity), e.aoMap && (t.aoMap.value = e.aoMap, t.aoMapIntensity.value = e.aoMapIntensity);
			var n;
			if(e.map ? n = e.map : e.specularMap ? n = e.specularMap : e.displacementMap ? n = e.displacementMap : e.normalMap ? n = e.normalMap : e.bumpMap ? n = e.bumpMap : e.roughnessMap ? n = e.roughnessMap : e.metalnessMap ? n = e.metalnessMap : e.alphaMap ? n = e.alphaMap : e.emissiveMap && (n = e.emissiveMap), void 0 !== n) {
				if(n.isWt && (n = n.texture), !0 === n.matrixAutoUpdate) {
					var i = n.offset,
						r = n.repeat,
						a = n.rotation,
						o = n.center;
					n.matrix.setUvTransform(i.x, i.y, r.x, r.y, a, o.x, o.y)
				}
				t.uvTransform.value.copy(n.matrix)
			}
		}

		function b(t, e) {
			t.diffuse.value = e.color, t.opacity.value = e.opacity
		}

		function w(t, e) {
			t.dashSize.value = e.dashSize, t.totalSize.value = e.dashSize + e.gapSize, t.scale.value = e.scale
		}

		function M(t, e) {
			if(t.diffuse.value = e.color, t.opacity.value = e.opacity, t.size.value = e.size * pt, t.scale.value = .5 * ft, t.map.value = e.map, null !== e.map) {
				if(!0 === e.map.matrixAutoUpdate) {
					var n = e.map.offset,
						i = e.map.repeat,
						r = e.map.rotation,
						a = e.map.center;
					e.map.matrix.setUvTransform(n.x, n.y, i.x, i.y, r, a.x, a.y)
				}
				t.uvTransform.value.copy(e.map.matrix)
			}
		}

		function S(t, e) {
			t.fogColor.value = e.color, e.isFog && (t.fogNear.value = e.near, t.fogFar.value = e.far)
		}

		function G(t, e) {
			e.emissiveMap && (t.emissiveMap.value = e.emissiveMap)
		}

		function E(t, e) {
			t.specular.value = e.specular, t.shininess.value = Math.max(e.shininess, 1e-4), e.emissiveMap && (t.emissiveMap.value = e.emissiveMap), e.bumpMap && (t.bumpMap.value = e.bumpMap, t.bumpScale.value = e.bumpScale), e.normalMap && (t.normalMap.value = e.normalMap, t.normalScale.value.copy(e.normalScale)), e.displacementMap && (t.displacementMap.value = e.displacementMap, t.displacementScale.value = e.displacementScale, t.displacementBias.value = e.displacementBias)
		}

		function T(t, e) {
			E(t, e), e.gradientMap && (t.gradientMap.value = e.gradientMap)
		}

		function A(t, e) {
			t.roughness.value = e.roughness, t.metalness.value = e.metalness, e.roughnessMap && (t.roughnessMap.value = e.roughnessMap), e.metalnessMap && (t.metalnessMap.value = e.metalnessMap), e.emissiveMap && (t.emissiveMap.value = e.emissiveMap), e.bumpMap && (t.bumpMap.value = e.bumpMap, t.bumpScale.value = e.bumpScale), e.normalMap && (t.normalMap.value = e.normalMap, t.normalScale.value.copy(e.normalScale)), e.displacementMap && (t.displacementMap.value = e.displacementMap, t.displacementScale.value = e.displacementScale, t.displacementBias.value = e.displacementBias), e.envMap && (t.envMapIntensity.value = e.envMapIntensity)
		}

		function L(t, e) {
			t.clearCoat.value = e.clearCoat, t.clearCoatRoughness.value = e.clearCoatRoughness, A(t, e)
		}

		function C(t, e) {
			e.displacementMap && (t.displacementMap.value = e.displacementMap, t.displacementScale.value = e.displacementScale, t.displacementBias.value = e.displacementBias)
		}

		function P(t, e) {
			e.displacementMap && (t.displacementMap.value = e.displacementMap, t.displacementScale.value = e.displacementScale, t.displacementBias.value = e.displacementBias), t.referencePosition.value.copy(e.referencePosition), t.nearDistance.value = e.nearDistance, t.farDistance.value = e.farDistance
		}

		function I(t, e) {
			e.bumpMap && (t.bumpMap.value = e.bumpMap, t.bumpScale.value = e.bumpScale), e.normalMap && (t.normalMap.value = e.normalMap, t.normalScale.value.copy(e.normalScale)), e.displacementMap && (t.displacementMap.value = e.displacementMap, t.displacementScale.value = e.displacementScale, t.displacementBias.value = e.displacementBias)
		}

		function R(t, e) {
			t.ambientLightColor.needsUpdate = e, t.directionalLights.needsUpdate = e, t.pointLights.needsUpdate = e, t.spotLights.needsUpdate = e, t.rectAreaLights.needsUpdate = e, t.hemisphereLights.needsUpdate = e
		}
		var O = void 0 !== (t = t || {}).canvas ? t.canvas : document.createElementNS("http://www.w3.org/1999/xhtml", "canvas"),
			N = void 0 !== t.context ? t.context : null,
			D = void 0 !== t.alpha && t.alpha,
			z = void 0 === t.depth || t.depth,
			U = void 0 === t.stencil || t.stencil,
			F = void 0 !== t.antialias && t.antialias,
			k = void 0 === t.premultipliedAlpha || t.premultipliedAlpha,
			B = void 0 !== t.preserveDrawingBuffer && t.preserveDrawingBuffer,
			V = [],
			j = [],
			H = null,
			W = [],
			Y = [];
		this.domElement = O, this.context = null, this.autoClear = !0, this.autoClearColor = !0, this.autoClearDepth = !0, this.autoClearStencil = !0, this.sortObjects = !0, this.cs = [], this.ld = !1, this.gammaFactor = 2, this.gammaInput = !1, this.gammaOutput = !1, this.physicallyCorrectLights = !1, this.toneMapping = Tr, this.toneMappingExposure = 1, this.toneMappingWhitePoint = 1, this.maxMorphTargets = 8, this.maxMorphNormals = 4;
		var q = this,
			J = !1,
			Q = null,
			$ = null,
			tt = -1,
			et = "",
			nt = null,
			it = null,
			st = new l,
			lt = new l,
			ct = null,
			ht = 0,
			ut = O.width,
			ft = O.height,
			pt = 1,
			dt = new l(0, 0, ut, ft),
			mt = new l(0, 0, ut, ft),
			gt = !1,
			vt = new rt,
			_t = new ve,
			yt = !1,
			xt = !1,
			bt = new i,
			wt = new a,
			Mt = {
				geometries: 0,
				textures: 0
			},
			St = {
				frame: 0,
				calls: 0,
				vertices: 0,
				faces: 0,
				points: 0
			};
		this.info = {
			render: St,
			memory: Mt,
			programs: null
		};
		var Gt;
		try {
			var Et = {
				alpha: D,
				depth: z,
				stencil: U,
				antialias: F,
				premultipliedAlpha: k,
				preserveDrawingBuffer: B
			};
			if(null === (Gt = N || O.getContext("webgl", Et) || O.getContext("experimental-webgl", Et))) throw null !== O.getContext("webgl") ? "Error creating WebGL context with your selected attributes." : "Error creating WebGL context.";
			void 0 === Gt.getShaderPrecisionFormat && (Gt.getShaderPrecisionFormat = function() {
				return {
					rangeMin: 1,
					rangeMax: 1,
					precision: 1
				}
			}), O.addEventListener("webglcontextlost", r, !1), O.addEventListener("webglcontextrestored", o, !1)
		} catch(t) {}
		var Tt, At, Lt, Ct, Pt, It, Rt, Ot, Nt, Dt, Ut, Ft, kt, Vt, Yt, Jt, Kt, Qt;
		n();
		var $t = new at(q, Ot, At.maxTextureSize);
		this.shadowMap = $t, this.getContext = function() {
			return Gt
		}, this.getContextAttributes = function() {
			return Gt.getContextAttributes()
		}, this.forceContextLoss = function() {
			var t = Tt.get("WEBGL_lose_context");
			t && t.loseContext()
		}, this.forceContextRestore = function() {
			var t = Tt.get("WEBGL_lose_context");
			t && t.restoreContext()
		}, this.getPixelRatio = function() {
			return pt
		}, this.so = function(t) {
			void 0 !== t && (pt = t, this.setSize(ut, ft, !1))
		}, this.getSize = function() {
			return {
				width: ut,
				height: ft
			}
		}, this.setSize = function(t, e, n) {
			ut = t, ft = e, O.width = t * pt, O.height = e * pt, !1 !== n && (O.style.width = t + "px", O.style.height = e + "px"), this.setViewport(0, 0, t, e)
		}, this.getDrawingBufferSize = function() {
			return {
				width: ut * pt,
				height: ft * pt
			}
		}, this.setDrawingBufferSize = function(t, e, n) {
			ut = t, ft = e, pt = n, O.width = t * n, O.height = e * n, this.setViewport(0, 0, t, e)
		}, this.setViewport = function(t, e, n, i) {
			dt.set(t, ft - e - i, n, i), Lt.viewport(st.copy(dt).multiplyScalar(pt))
		}, this.setScissor = function(t, e, n, i) {
			mt.set(t, ft - e - i, n, i), Lt.scissor(lt.copy(mt).multiplyScalar(pt))
		}, this.setScissorTest = function(t) {
			Lt.setScissorTest(gt = t)
		}, this.getClearColor = function() {
			return Ft.getClearColor()
		}, this.sr = function() {
			Ft.sr.apply(Ft, arguments)
		}, this.getClearAlpha = function() {
			return Ft.getClearAlpha()
		}, this.setClearAlpha = function() {
			Ft.setClearAlpha.apply(Ft, arguments)
		}, this.clear = function(t, e, n) {
			var i = 0;
			(void 0 === t || t) && (i |= Gt.COLOR_BUFFER_BIT), (void 0 === e || e) && (i |= Gt.DEPTH_BUFFER_BIT), (void 0 === n || n) && (i |= Gt.STENCIL_BUFFER_BIT), Gt.clear(i)
		}, this.clearColor = function() {
			this.clear(!0, !1, !1)
		}, this.clearDepth = function() {
			this.clear(!1, !0, !1)
		}, this.clearStencil = function() {
			this.clear(!1, !1, !0)
		}, this.clearTarget = function(t, e, n, i) {
			this.setRenderTarget(t), this.clear(e, n, i)
		}, this.dispose = function() {
			O.removeEventListener("webglcontextlost", r, !1), O.removeEventListener("webglcontextrestored", o, !1), Ut.dispose()
		}, this.renderBufferImmediate = function(t, e, n) {
			Lt.initAttributes();
			var i = Ct.get(t);
			t.hasPositions && !i.position && (i.position = Gt.createBuffer()), t.hasNormals && !i.normal && (i.normal = Gt.createBuffer()), t.hasUvs && !i.uv && (i.uv = Gt.createBuffer()), t.hasColors && !i.color && (i.color = Gt.createBuffer());
			var r = e.getAttributes();
			if(t.hasPositions && (Gt.bindBuffer(Gt.ARRAY_BUFFER, i.position), Gt.bufferData(Gt.ARRAY_BUFFER, t.positionArray, Gt.DYNAMIC_DRAW), Lt.enableAttribute(r.position), Gt.vertexAttribPointer(r.position, 3, Gt.FLOAT, !1, 0, 0)), t.hasNormals) {
				if(Gt.bindBuffer(Gt.ARRAY_BUFFER, i.normal), !n.isMeshPhongMaterial && !n.isMeshStandardMaterial && !n.isMeshNormalMaterial && !0 === n.flatShading)
					for(var a = 0, o = 3 * t.count; a < o; a += 9) {
						var s = t.normalArray,
							l = (s[a + 0] + s[a + 3] + s[a + 6]) / 3,
							c = (s[a + 1] + s[a + 4] + s[a + 7]) / 3,
							h = (s[a + 2] + s[a + 5] + s[a + 8]) / 3;
						s[a + 0] = l, s[a + 1] = c, s[a + 2] = h, s[a + 3] = l, s[a + 4] = c, s[a + 5] = h, s[a + 6] = l, s[a + 7] = c, s[a + 8] = h
					}
				Gt.bufferData(Gt.ARRAY_BUFFER, t.normalArray, Gt.DYNAMIC_DRAW), Lt.enableAttribute(r.normal), Gt.vertexAttribPointer(r.normal, 3, Gt.FLOAT, !1, 0, 0)
			}
			t.hasUvs && n.map && (Gt.bindBuffer(Gt.ARRAY_BUFFER, i.uv), Gt.bufferData(Gt.ARRAY_BUFFER, t.uvArray, Gt.DYNAMIC_DRAW), Lt.enableAttribute(r.uv), Gt.vertexAttribPointer(r.uv, 2, Gt.FLOAT, !1, 0, 0)), t.hasColors && n.vertexColors !== Wi && (Gt.bindBuffer(Gt.ARRAY_BUFFER, i.color), Gt.bufferData(Gt.ARRAY_BUFFER, t.colorArray, Gt.DYNAMIC_DRAW), Lt.enableAttribute(r.color), Gt.vertexAttribPointer(r.color, 3, Gt.FLOAT, !1, 0, 0)), Lt.disableUnusedAttributes(), Gt.drawArrays(Gt.TRIANGLES, 0, t.count), t.count = 0
		}, this.renderBufferDirect = function(t, n, i, r, a, o) {
			Lt.setMaterial(r);
			var s = y(t, n, r, a),
				l = i.id + "_" + s.id + "_" + (!0 === r.wireframe),
				c = !1;
			l !== et && (et = l, c = !0), a.morphTargetInfluences && (kt.update(a, i, r, s), c = !0);
			var h = i.index,
				u = i.attributes.position,
				p = 1;
			!0 === r.wireframe && (h = Rt.getWireframeAttribute(i), p = 2);
			var d, m = Vt;
			null !== h && (d = It.get(h), (m = Yt).setIndex(d)), c && (f(r, s, i), null !== h && Gt.bindBuffer(Gt.ELEMENT_ARRAY_BUFFER, d.buffer));
			var g = 0;
			null !== h ? g = h.count : void 0 !== u && (g = u.count);
			var v = i.drawRange.start * p,
				_ = i.drawRange.count * p,
				x = null !== o ? o.start * p : 0,
				b = null !== o ? o.count * p : 1 / 0,
				w = Math.max(v, x),
				M = Math.min(g, v + _, x + b) - 1,
				S = Math.max(0, M - w + 1);
			if(0 !== S) {
				if(a.isMesh)
					if(!0 === r.wireframe) Lt.setLineWidth(r.wireframeLinewidth * e()), m.setMode(Gt.LINES);
					else switch(a.drawMode) {
						case wa:
							m.setMode(Gt.TRIANGLES);
							break;
						case Ma:
							m.setMode(Gt.TRIANGLE_STRIP);
							break;
						case Sa:
							m.setMode(Gt.TRIANGLE_FAN)
					} else if(a.isLine) {
						var G = r.linewidth;
						void 0 === G && (G = 1), Lt.setLineWidth(G * e()), a.isLineSegments ? m.setMode(Gt.LINES) : a.isLineLoop ? m.setMode(Gt.LINE_LOOP) : m.setMode(Gt.LINE_STRIP)
					} else a.isPoints && m.setMode(Gt.POINTS);
				i && i.isInstancedBufferGeometry ? i.maxInstancedCount > 0 && m.renderInstances(i, w, S) : m.render(w, S)
			}
		}, this.compile = function(t, e) {
			V.length = 0, j.length = 0, t.traverse(function(t) {
				t.isLight && (V.push(t), t.castShadow && j.push(t))
			}), Nt.setup(V, j, e), t.traverse(function(e) {
				if(e.material)
					if(Array.isArray(e.material))
						for(var n = 0; n < e.material.length; n++) _(e.material[n], t.fog, e);
					else _(e.material, t.fog, e)
			})
		};
		var te = !1,
			ee = null;
		this.animate = function(t) {
			ee = t, p()
		}, this.render = function(t, e, n, i) {
			if(e && e.isCamera && !J) {
				et = "", tt = -1, nt = null, !0 === t.autoUpdate && t.uld(), null === e.parent && e.uld(), bt.multiplyMatrices(e.projectionMatrix, e.matrixWorldInverse), vt.setFromMatrix(bt), V.length = 0, j.length = 0, W.length = 0, Y.length = 0, xt = this.ld, yt = _t.init(this.cs, xt, e), (H = Ut.get(t, e)).init(), m(t, e, q.sortObjects), !0 === q.sortObjects && H.sort(), yt && _t.beginShadows(), $t.render(j, t, e), Nt.setup(V, j, e), yt && _t.endShadows(), St.frame++, St.calls = 0, St.vertices = 0, St.faces = 0, St.points = 0, void 0 === n && (n = null), this.setRenderTarget(n), Ft.render(H, t, e, i);
				var r = H.opaque,
					a = H.transparent;
				if(t.overrideMaterial) {
					var o = t.overrideMaterial;
					r.length && g(r, t, e, o), a.length && g(a, t, e, o)
				} else r.length && g(r, t, e), a.length && g(a, t, e);
				Kt.render(W, t, e), Jt.render(Y, t, e, st), n && Pt.updateRenderTargetMipmap(n), Lt.buffers.depth.setTest(!0), Lt.buffers.depth.setMask(!0), Lt.buffers.color.setMask(!0), Lt.setPolygonOffset(!1)
			}
		}, this.setFaceCulling = function(t, e) {
			Lt.setCullFace(t), Lt.setFlipSided(e === Fi)
		}, this.allocTextureUnit = function() {
			var t = ht;
			return At.maxTextures, ht += 1, t
		}, this.setTexture2D = function() {
			var t = !1;
			return function(e, n) {
				e && e.isWt && (t || (t = !0), e = e.texture), Pt.setTexture2D(e, n)
			}
		}(), this.setTexture = function() {
			var t = !1;
			return function(e, n) {
				t || (t = !0), Pt.setTexture2D(e, n)
			}
		}(), this.setTextureCube = function() {
			var t = !1;
			return function(e, n) {
				e && e.isWtCube && (t || (t = !0), e = e.texture), e && e.isCubeTexture || Array.isArray(e.image) && 6 === e.image.length ? Pt.setTextureCube(e, n) : Pt.setTextureCubeDynamic(e, n)
			}
		}(), this.getRenderTarget = function() {
			return Q
		}, this.setRenderTarget = function(t) {
			Q = t, t && void 0 === Ct.get(t).__webglFramebuffer && Pt.setupRenderTarget(t);
			var e = null,
				n = !1;
			if(t) {
				var i = Ct.get(t).__webglFramebuffer;
				t.isWtCube ? (e = i[t.activeCubeFace], n = !0) : e = i, st.copy(t.viewport), lt.copy(t.scissor), ct = t.scissorTest
			} else st.copy(dt).multiplyScalar(pt), lt.copy(mt).multiplyScalar(pt), ct = gt;
			if($ !== e && (Gt.bindFramebuffer(Gt.FRAMEBUFFER, e), $ = e), Lt.viewport(st), Lt.scissor(lt), Lt.setScissorTest(ct), n) {
				var r = Ct.get(t.texture);
				Gt.framebufferTexture2D(Gt.FRAMEBUFFER, Gt.COLOR_ATTACHMENT0, Gt.TEXTURE_CUBE_MAP_POSITIVE_X + t.activeCubeFace, r.__webglTexture, t.activeMipMapLevel)
			}
		}, this.rls = function(t, e, n, i, r, a) {
			if(t && t.isWt) {
				var o = Ct.get(t).__webglFramebuffer;
				if(o) {
					var s = !1;
					o !== $ && (Gt.bindFramebuffer(Gt.FRAMEBUFFER, o), s = !0);
					try {
						var l = t.texture,
							c = l.format,
							h = l.type;
						if(c !== sa && Qt.convert(c) !== Gt.getParameter(Gt.IMPLEMENTATION_COLOR_READ_FORMAT)) return;
						if(!(h === Yr || Qt.convert(h) === Gt.getParameter(Gt.IMPLEMENTATION_COLOR_READ_TYPE) || h === $r && (Tt.get("OES_texture_float") || Tt.get("WEBGL_color_buffer_float")) || h === ta && Tt.get("EXT_color_buffer_half_float"))) return;
						Gt.checkFramebufferStatus(Gt.FRAMEBUFFER) === Gt.FRAMEBUFFER_COMPLETE && e >= 0 && e <= t.width - i && n >= 0 && n <= t.height - r && Gt.readPixels(e, n, i, r, Qt.convert(c), Qt.convert(h), a)
					} finally {
						s && Gt.bindFramebuffer(Gt.FRAMEBUFFER, $)
					}
				}
			}
		}
	}

	function xe(t, e, n) {
		this.name = "", this.color = new Y(t), this.near = void 0 !== e ? e : 1, this.far = void 0 !== n ? n : 1e3
	}

	function be() {
		ct.call(this), this.type = "Scene", this.background = null, this.fog = null, this.overrideMaterial = null, this.autoUpdate = !0
	}

	function we(t, e, n, i, r) {
		ct.call(this), this.lensFlares = [], this.positionScreen = new a, this.customUpdateCallback = void 0, void 0 !== t && this.add(t, e, n, i, r)
	}

	function Me(t) {
		Q.call(this), this.type = "SpriteMaterial", this.color = new Y(16777215), this.map = null, this.rotation = 0, this.fog = !1, this.lights = !1, this.setValues(t)
	}

	function Se(t) {
		ct.call(this), this.type = "Sprite", this.material = void 0 !== t ? t : new Me
	}

	function Ge(t, e) {
		if(t = t || [], this.bones = t.slice(0), this.boneMatrices = new Float32Array(16 * this.bones.length), void 0 === e) this.calculateInverses();
		else if(this.bones.length === e.length) this.boneInverses = e.slice(0);
		else {
			this.boneInverses = [];
			for(var n = 0, r = this.bones.length; n < r; n++) this.boneInverses.push(new i)
		}
	}

	function Ee() {
		ct.call(this), this.type = "Bone"
	}

	function Te(t, e) {
		Dt.call(this, t, e), this.type = "SkinnedMesh", this.bindMode = "attached", this.bindMatrix = new i, this.bindMatrixInverse = new i;
		var n = new Ge(this.initBones());
		this.bind(n, this.matrixWorld), this.normalizeSkinWeights()
	}

	function Ae(t) {
		Q.call(this), this.type = "LineBasicMaterial", this.color = new Y(16777215), this.linewidth = 1, this.linecap = "round", this.linejoin = "round", this.lights = !1, this.setValues(t)
	}

	function Le(t, e, n) {
		if(1 === n) return new Ce(t, e);
		ct.call(this), this.type = "Line", this.geometry = void 0 !== t ? t : new Et, this.material = void 0 !== e ? e : new Ae({
			color: 16777215 * Math.random()
		})
	}

	function Ce(t, e) {
		Le.call(this, t, e), this.type = "LineSegments"
	}

	function Pe(t, e) {
		Le.call(this, t, e), this.type = "LineLoop"
	}

	function Ie(t) {
		Q.call(this), this.type = "PointsMaterial", this.color = new Y(16777215), this.map = null, this.size = 1, this.sizeAttenuation = !0, this.lights = !1, this.setValues(t)
	}

	function Re(t, e) {
		ct.call(this), this.type = "Points", this.geometry = void 0 !== t ? t : new Et, this.material = void 0 !== e ? e : new Ie({
			color: 16777215 * Math.random()
		})
	}

	function Oe() {
		ct.call(this), this.type = "Group"
	}

	function Ne(t, e, n, i, r, a, o, l, c) {
		function h() {
			var t = u.image;
			t.readyState >= t.HAVE_CURRENT_DATA && (u.needsUpdate = !0), requestAnimationFrame(h)
		}
		s.call(this, t, e, n, i, r, a, o, l, c), this.generateMipmaps = !1;
		var u = this;
		requestAnimationFrame(h)
	}

	function De(t, e, n, i, r, a, o, l, c, h, u, f) {
		s.call(this, null, a, o, l, c, h, i, r, u, f), this.image = {
			width: e,
			height: n
		}, this.mipmaps = t, this.flipY = !1, this.generateMipmaps = !1
	}

	function ze(t, e, n, i, r, a, o, l, c, h) {
		h = void 0 !== h ? h : ua, void 0 === n && h === ua && (n = Jr), void 0 === n && h === fa && (n = ra), s.call(this, null, i, r, a, o, l, h, n, c), this.image = {
			width: t,
			height: e
		}, this.magFilter = void 0 !== o ? o : Br, this.minFilter = void 0 !== l ? l : Br, this.flipY = !1, this.generateMipmaps = !1
	}

	function Ue(t) {
		Et.call(this), this.type = "WireframeGeometry";
		var e, n, i, r, o, s, l, c, h, u, f = [],
			p = [0, 0],
			d = {},
			m = ["a", "b", "c"];
		if(t && t.isGeometry) {
			var g = t.faces;
			for(e = 0, i = g.length; e < i; e++) {
				var v = g[e];
				for(n = 0; n < 3; n++) l = v[m[n]], c = v[m[(n + 1) % 3]], p[0] = Math.min(l, c), p[1] = Math.max(l, c), void 0 === d[h = p[0] + "," + p[1]] && (d[h] = {
					index1: p[0],
					index2: p[1]
				})
			}
			for(h in d) s = d[h], u = t.vertices[s.index1], f.push(u.x, u.y, u.z), u = t.vertices[s.index2], f.push(u.x, u.y, u.z)
		} else if(t && t.isBufferGeometry) {
			var _, y, x, b, w, M, S;
			if(u = new a, null !== t.index) {
				for(_ = t.attributes.position, y = t.index, 0 === (x = t.groups).length && (x = [{
						start: 0,
						count: y.count,
						materialIndex: 0
					}]), r = 0, o = x.length; r < o; ++r)
					for(e = w = (b = x[r]).start, i = w + b.count; e < i; e += 3)
						for(n = 0; n < 3; n++) l = y.getX(e + n), c = y.getX(e + (n + 1) % 3), p[0] = Math.min(l, c), p[1] = Math.max(l, c), void 0 === d[h = p[0] + "," + p[1]] && (d[h] = {
							index1: p[0],
							index2: p[1]
						});
				for(h in d) s = d[h], u.fromBufferAttribute(_, s.index1), f.push(u.x, u.y, u.z), u.fromBufferAttribute(_, s.index2), f.push(u.x, u.y, u.z)
			} else
				for(e = 0, i = (_ = t.attributes.position).count / 3; e < i; e++)
					for(n = 0; n < 3; n++) M = 3 * e + n, u.fromBufferAttribute(_, M), f.push(u.x, u.y, u.z), S = 3 * e + (n + 1) % 3, u.fromBufferAttribute(_, S), f.push(u.x, u.y, u.z)
		}
		this.addAttribute("position", new wt(f, 3))
	}

	function Fe(t, e, n, i, r, a, o) {
		pt.call(this), this.type = "SphereGeometry", this.parameters = {
			radius: t,
			widthSegments: e,
			heightSegments: n,
			phiStart: i,
			phiLength: r,
			thetaStart: a,
			thetaLength: o
		}, this.fromBufferGeometry(new ke(t, e, n, i, r, a, o)), this.mergeVertices()
	}

	function ke(t, e, n, i, r, o, s) {
		Et.call(this), this.type = "SphereBufferGeometry", this.parameters = {
			radius: t,
			widthSegments: e,
			heightSegments: n,
			phiStart: i,
			phiLength: r,
			thetaStart: o,
			thetaLength: s
		}, t = t || 1, e = Math.max(3, Math.floor(e) || 8), n = Math.max(2, Math.floor(n) || 6), i = void 0 !== i ? i : 0, r = void 0 !== r ? r : 2 * Math.PI;
		var l, c, h = (o = void 0 !== o ? o : 0) + (s = void 0 !== s ? s : Math.PI),
			u = 0,
			f = [],
			p = new a,
			d = new a,
			m = [],
			g = [],
			v = [],
			_ = [];
		for(c = 0; c <= n; c++) {
			var y = [],
				x = c / n;
			for(l = 0; l <= e; l++) {
				var b = l / e;
				p.x = -t * Math.cos(i + b * r) * Math.sin(o + x * s), p.y = t * Math.cos(o + x * s), p.z = t * Math.sin(i + b * r) * Math.sin(o + x * s), g.push(p.x, p.y, p.z), d.set(p.x, p.y, p.z).normalize(), v.push(d.x, d.y, d.z), _.push(b, 1 - x), y.push(u++)
			}
			f.push(y)
		}
		for(c = 0; c < n; c++)
			for(l = 0; l < e; l++) {
				var w = f[c][l + 1],
					M = f[c][l],
					S = f[c + 1][l],
					G = f[c + 1][l + 1];
				(0 !== c || o > 0) && m.push(w, M, G), (c !== n - 1 || h < Math.PI) && m.push(M, S, G)
			}
		this.setIndex(m), this.addAttribute("position", new wt(g, 3)), this.addAttribute("normal", new wt(v, 3)), this.addAttribute("uv", new wt(_, 2))
	}

	function Be(t, e) {
		pt.call(this), this.type = "ShapeGeometry", "object" == typeof e && (e = e.curveSegments), this.parameters = {
			shapes: t,
			curveSegments: e
		}, this.fromBufferGeometry(new Ve(t, e)), this.mergeVertices()
	}

	function Ve(t, e) {
		function n(t) {
			var n, s, c, h = r.length / 3,
				u = t.extractPoints(e),
				f = u.shape,
				p = u.holes;
			if(!1 === $a.isClockWise(f))
				for(f = f.reverse(), n = 0, s = p.length; n < s; n++) c = p[n], !0 === $a.isClockWise(c) && (p[n] = c.reverse());
			var d = $a.triangulateShape(f, p);
			for(n = 0, s = p.length; n < s; n++) c = p[n], f = f.concat(c);
			for(n = 0, s = f.length; n < s; n++) {
				var m = f[n];
				r.push(m.x, m.y, 0), a.push(0, 0, 1), o.push(m.x, m.y)
			}
			for(n = 0, s = d.length; n < s; n++) {
				var g = d[n],
					v = g[0] + h,
					_ = g[1] + h,
					y = g[2] + h;
				i.push(v, _, y), l += 3
			}
		}
		Et.call(this), this.type = "ShapeBufferGeometry", this.parameters = {
			shapes: t,
			curveSegments: e
		}, e = e || 12;
		var i = [],
			r = [],
			a = [],
			o = [],
			s = 0,
			l = 0;
		if(!1 === Array.isArray(t)) n(t);
		else
			for(var c = 0; c < t.length; c++) n(t[c]), this.addGroup(s, l, c), s += l, l = 0;
		this.setIndex(i), this.addAttribute("position", new wt(r, 3)), this.addAttribute("normal", new wt(a, 3)), this.addAttribute("uv", new wt(o, 2))
	}

	function je(t, e) {
		Et.call(this), this.type = "EdgesGeometry", this.parameters = {
			thresholdAngle: e
		}, e = void 0 !== e ? e : 1;
		var n, i, r, a, o = [],
			s = Math.cos(Oa.DEG2RAD * e),
			l = [0, 0],
			c = {},
			h = ["a", "b", "c"];
		t.isBufferGeometry ? (a = new pt).fromBufferGeometry(t) : a = t.clone(), a.mergeVertices(), a.computeFaceNormals();
		for(var u = a.vertices, f = a.faces, p = 0, d = f.length; p < d; p++)
			for(var m = f[p], g = 0; g < 3; g++) n = m[h[g]], i = m[h[(g + 1) % 3]], l[0] = Math.min(n, i), l[1] = Math.max(n, i), void 0 === c[r = l[0] + "," + l[1]] ? c[r] = {
				index1: l[0],
				index2: l[1],
				face1: p,
				face2: void 0
			} : c[r].face2 = p;
		for(r in c) {
			var v = c[r];
			if(void 0 === v.face2 || f[v.face1].normal.dot(f[v.face2].normal) <= s) {
				var _ = u[v.index1];
				o.push(_.x, _.y, _.z), _ = u[v.index2], o.push(_.x, _.y, _.z)
			}
		}
		this.addAttribute("position", new wt(o, 3))
	}

	function He(t, e, n, i, r, a, o, s) {
		pt.call(this), this.type = "CylinderGeometry", this.parameters = {
			radiusTop: t,
			radiusBottom: e,
			height: n,
			radialSegments: i,
			heightSegments: r,
			openEnded: a,
			thetaStart: o,
			thetaLength: s
		}, this.fromBufferGeometry(new We(t, e, n, i, r, a, o, s)), this.mergeVertices()
	}

	function We(t, e, i, r, o, s, l, c) {
		function h(i) {
			var o, s, h, v = new n,
				x = new a,
				b = 0,
				w = !0 === i ? t : e,
				M = !0 === i ? 1 : -1;
			for(s = g, o = 1; o <= r; o++) p.push(0, _ * M, 0), d.push(0, M, 0), m.push(.5, .5), g++;
			for(h = g, o = 0; o <= r; o++) {
				var S = o / r * c + l,
					G = Math.cos(S),
					E = Math.sin(S);
				x.x = w * E, x.y = _ * M, x.z = w * G, p.push(x.x, x.y, x.z), d.push(0, M, 0), v.x = .5 * G + .5, v.y = .5 * E * M + .5, m.push(v.x, v.y), g++
			}
			for(o = 0; o < r; o++) {
				var T = s + o,
					A = h + o;
				!0 === i ? f.push(A, A + 1, T) : f.push(A + 1, A, T), b += 3
			}
			u.addGroup(y, b, !0 === i ? 1 : 2), y += b
		}
		Et.call(this), this.type = "CylinderBufferGeometry", this.parameters = {
			radiusTop: t,
			radiusBottom: e,
			height: i,
			radialSegments: r,
			heightSegments: o,
			openEnded: s,
			thetaStart: l,
			thetaLength: c
		};
		var u = this;
		t = void 0 !== t ? t : 1, e = void 0 !== e ? e : 1, i = i || 1, r = Math.floor(r) || 8, o = Math.floor(o) || 1, s = void 0 !== s && s, l = void 0 !== l ? l : 0, c = void 0 !== c ? c : 2 * Math.PI;
		var f = [],
			p = [],
			d = [],
			m = [],
			g = 0,
			v = [],
			_ = i / 2,
			y = 0;
		! function() {
			var n, s, h = new a,
				x = new a,
				b = 0,
				w = (e - t) / i;
			for(s = 0; s <= o; s++) {
				var M = [],
					S = s / o,
					G = S * (e - t) + t;
				for(n = 0; n <= r; n++) {
					var E = n / r,
						T = E * c + l,
						A = Math.sin(T),
						L = Math.cos(T);
					x.x = G * A, x.y = -S * i + _, x.z = G * L, p.push(x.x, x.y, x.z), h.set(A, w, L).normalize(), d.push(h.x, h.y, h.z), m.push(E, 1 - S), M.push(g++)
				}
				v.push(M)
			}
			for(n = 0; n < r; n++)
				for(s = 0; s < o; s++) {
					var C = v[s][n],
						P = v[s + 1][n],
						I = v[s + 1][n + 1],
						R = v[s][n + 1];
					f.push(C, P, R), f.push(P, I, R), b += 6
				}
			u.addGroup(y, b, 0), y += b
		}(), !1 === s && (t > 0 && h(!0), e > 0 && h(!1)), this.setIndex(f), this.addAttribute("position", new wt(p, 3)), this.addAttribute("normal", new wt(d, 3)), this.addAttribute("uv", new wt(m, 2))
	}

	function Xe(t, e, n, i, r, a, o) {
		He.call(this, 0, t, e, n, i, r, a, o), this.type = "ConeGeometry", this.parameters = {
			radius: t,
			height: e,
			radialSegments: n,
			heightSegments: i,
			openEnded: r,
			thetaStart: a,
			thetaLength: o
		}
	}

	function Ye(t, e, n, i, r, a, o) {
		We.call(this, 0, t, e, n, i, r, a, o), this.type = "ConeBufferGeometry", this.parameters = {
			radius: t,
			height: e,
			radialSegments: n,
			heightSegments: i,
			openEnded: r,
			thetaStart: a,
			thetaLength: o
		}
	}

	function qe(t, e, n, i) {
		pt.call(this), this.type = "CircleGeometry", this.parameters = {
			radius: t,
			segments: e,
			thetaStart: n,
			thetaLength: i
		}, this.fromBufferGeometry(new Ze(t, e, n, i)), this.mergeVertices()
	}

	function Ze(t, e, i, r) {
		Et.call(this), this.type = "CircleBufferGeometry", this.parameters = {
			radius: t,
			segments: e,
			thetaStart: i,
			thetaLength: r
		}, t = t || 1, e = void 0 !== e ? Math.max(3, e) : 8, i = void 0 !== i ? i : 0, r = void 0 !== r ? r : 2 * Math.PI;
		var o, s, l = [],
			c = [],
			h = [],
			u = [],
			f = new a,
			p = new n;
		for(c.push(0, 0, 0), h.push(0, 0, 1), u.push(.5, .5), s = 0, o = 3; s <= e; s++, o += 3) {
			var d = i + s / e * r;
			f.x = t * Math.cos(d), f.y = t * Math.sin(d), c.push(f.x, f.y, f.z), h.push(0, 0, 1), p.x = (c[o] / t + 1) / 2, p.y = (c[o + 1] / t + 1) / 2, u.push(p.x, p.y)
		}
		for(o = 1; o <= e; o++) l.push(o, o + 1, 0);
		this.setIndex(l), this.addAttribute("position", new wt(c, 3)), this.addAttribute("normal", new wt(h, 3)), this.addAttribute("uv", new wt(u, 2))
	}

	function Je(t) {
		Q.call(this), this.type = "ShadowMaterial", this.color = new Y(0), this.opacity = 1, this.lights = !0, this.transparent = !0, this.setValues(t)
	}

	function Ke(t) {
		It.call(this, t), this.type = "RawShaderMaterial"
	}

	function Qe(t) {
		Q.call(this), this.defines = {
			STANDARD: ""
		}, this.type = "MeshStandardMaterial", this.color = new Y(16777215), this.roughness = .5, this.metalness = .5, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new Y(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalScale = new n(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.roughnessMap = null, this.metalnessMap = null, this.alphaMap = null, this.envMap = null, this.envMapIntensity = 1, this.refractionRatio = .98, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.skinning = !1, this.morphTargets = !1, this.morphNormals = !1, this.setValues(t)
	}

	function $e(t) {
		Qe.call(this), this.defines = {
			PHYSICAL: ""
		}, this.type = "MeshPhysicalMaterial", this.reflectivity = .5, this.clearCoat = 0, this.clearCoatRoughness = 0, this.setValues(t)
	}

	function tn(t) {
		Q.call(this), this.type = "MeshPhongMaterial", this.color = new Y(16777215), this.specular = new Y(1118481), this.shininess = 30, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new Y(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalScale = new n(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.specularMap = null, this.alphaMap = null, this.envMap = null, this.combine = Mr, this.reflectivity = 1, this.refractionRatio = .98, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.skinning = !1, this.morphTargets = !1, this.morphNormals = !1, this.setValues(t)
	}

	function en(t) {
		tn.call(this), this.defines = {
			TOON: ""
		}, this.type = "MeshToonMaterial", this.gradientMap = null, this.setValues(t)
	}

	function nn(t) {
		Q.call(this), this.type = "MeshNormalMaterial", this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalScale = new n(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.wireframe = !1, this.wireframeLinewidth = 1, this.fog = !1, this.lights = !1, this.skinning = !1, this.morphTargets = !1, this.morphNormals = !1, this.setValues(t)
	}

	function rn(t) {
		Q.call(this), this.type = "MeshLambertMaterial", this.color = new Y(16777215), this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new Y(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.specularMap = null, this.alphaMap = null, this.envMap = null, this.combine = Mr, this.reflectivity = 1, this.refractionRatio = .98, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.skinning = !1, this.morphTargets = !1, this.morphNormals = !1, this.setValues(t)
	}

	function an(t) {
		Ae.call(this), this.type = "LineDashedMaterial", this.scale = 1, this.dashSize = 3, this.gapSize = 1, this.setValues(t)
	}

	function on(t, e, n) {
		var i = this,
			r = !1,
			a = 0,
			o = 0,
			s = void 0;
		this.onStart = void 0, this.onLoad = t, this.onProgress = e, this.onError = n, this.itemStart = function(t) {
			o++, !1 === r && void 0 !== i.onStart && i.onStart(t, a, o), r = !0
		}, this.itemEnd = function(t) {
			a++, void 0 !== i.onProgress && i.onProgress(t, a, o), a === o && (r = !1, void 0 !== i.onLoad && i.onLoad())
		}, this.itemError = function(t) {
			void 0 !== i.onError && i.onError(t)
		}, this.resolveURL = function(t) {
			return s ? s(t) : t
		}, this.setURLModifier = function(t) {
			s = t
		}
	}

	function sn(t) {
		this.manager = void 0 !== t ? t : io
	}

	function ln(t) {
		this.manager = void 0 !== t ? t : io, this._parser = null
	}

	function cn(t) {
		this.manager = void 0 !== t ? t : io, this._parser = null
	}

	function hn(t) {
		this.manager = void 0 !== t ? t : io
	}

	function un(t) {
		this.manager = void 0 !== t ? t : io
	}

	function fn(t) {
		this.manager = void 0 !== t ? t : io
	}

	function pn(t, e) {
		ct.call(this), this.type = "Light", this.color = new Y(t), this.intensity = void 0 !== e ? e : 1, this.receiveShadow = void 0
	}

	function dn(t, e, n) {
		pn.call(this, t, n), this.type = "HemisphereLight", this.castShadow = void 0, this.position.copy(ct.DefaultUp), this.updateMatrix(), this.groundColor = new Y(e)
	}

	function mn(t) {
		this.camera = t, this.bias = 0, this.radius = 1, this.mapSize = new n(512, 512), this.map = null, this.matrix = new i
	}

	function gn() {
		mn.call(this, new de(50, 1, .5, 500))
	}

	function vn(t, e, n, i, r, a) {
		pn.call(this, t, e), this.type = "SpotLight", this.position.copy(ct.DefaultUp), this.updateMatrix(), this.target = new ct, Object.defineProperty(this, "power", {
			get: function() {
				return this.intensity * Math.PI
			},
			set: function(t) {
				this.intensity = t / Math.PI
			}
		}), this.distance = void 0 !== n ? n : 0, this.angle = void 0 !== i ? i : Math.PI / 3, this.penumbra = void 0 !== r ? r : 0, this.decay = void 0 !== a ? a : 1, this.shadow = new gn
	}

	function _n(t, e, n, i) {
		pn.call(this, t, e), this.type = "PointLight", Object.defineProperty(this, "power", {
			get: function() {
				return 4 * this.intensity * Math.PI
			},
			set: function(t) {
				this.intensity = t / (4 * Math.PI)
			}
		}), this.distance = void 0 !== n ? n : 0, this.decay = void 0 !== i ? i : 1, this.shadow = new mn(new de(90, 1, .5, 500))
	}

	function yn() {
		mn.call(this, new ut(-5, 5, 5, -5, .5, 500))
	}

	function xn(t, e) {
		pn.call(this, t, e), this.type = "Dt", this.position.copy(ct.DefaultUp), this.updateMatrix(), this.target = new ct, this.shadow = new yn
	}

	function bn(t, e) {
		pn.call(this, t, e), this.type = "AmbientLight", this.castShadow = void 0
	}

	function wn(t, e, n, i) {
		pn.call(this, t, e), this.type = "RectAreaLight", this.position.set(0, 1, 0), this.updateMatrix(), this.width = void 0 !== n ? n : 10, this.height = void 0 !== i ? i : 10
	}

	function Mn(t, e, n, i) {
		this.parameterPositions = t, this._cachedIndex = 0, this.resultBuffer = void 0 !== i ? i : new e.constructor(n), this.sampleValues = e, this.valueSize = n
	}

	function Sn(t, e, n, i) {
		Mn.call(this, t, e, n, i)
	}

	function Gn(t, e, n, i) {
		Cn.call(this, t, e, n, i)
	}

	function En(t, e, n, i) {
		Cn.call(this, t, e, n, i)
	}

	function Tn(t, e, n, i) {
		Mn.call(this, t, e, n, i), this._weightPrev = -0, this._offsetPrev = -0, this._weightNext = -0, this._offsetNext = -0
	}

	function An(t, e, n, i) {
		Mn.call(this, t, e, n, i)
	}

	function Ln(t, e, n, i) {
		Mn.call(this, t, e, n, i)
	}

	function Cn(t, e, n, i) {
		this.name = t, this.times = ao.convertArray(e, this.TimeBufferType), this.values = ao.convertArray(n, this.ValueBufferType), this.setInterpolation(i || this.DefaultInterpolation), this.validate(), this.optimize()
	}

	function Pn(t, e, n, i) {
		Cn.call(this, t, e, n, i)
	}

	function In(t, e, n) {
		this.name = t, this.tracks = n, this.duration = void 0 !== e ? e : -1, this.uuid = Oa.generateUUID(), this.duration < 0 && this.resetDuration(), this.optimize()
	}

	function Rn(t) {
		this.manager = void 0 !== t ? t : io, this.textures = {}
	}

	function On(t) {
		this.manager = void 0 !== t ? t : io
	}

	function Nn() {
		this.onLoadStart = function() {}, this.onLoadProgress = function() {}, this.onLoadComplete = function() {}
	}

	function Dn(t) {
		"boolean" == typeof t && (t = void 0), this.manager = void 0 !== t ? t : io, this.withCredentials = !1
	}

	function zn(t) {
		this.manager = void 0 !== t ? t : io, this.texturePath = ""
	}

	function Un(t, e, n, i, r) {
		var a = .5 * (i - e),
			o = .5 * (r - n),
			s = t * t;
		return(2 * n - 2 * i + a + o) * (t * s) + (-3 * n + 3 * i - 2 * a - o) * s + a * t + n
	}

	function Fn(t, e) {
		var n = 1 - t;
		return n * n * e
	}

	function kn(t, e) {
		return 2 * (1 - t) * t * e
	}

	function Bn(t, e) {
		return t * t * e
	}

	function Vn(t, e, n, i) {
		return Fn(t, e) + kn(t, n) + Bn(t, i)
	}

	function jn(t, e) {
		var n = 1 - t;
		return n * n * n * e
	}

	function Hn(t, e) {
		var n = 1 - t;
		return 3 * n * n * t * e
	}

	function Wn(t, e) {
		return 3 * (1 - t) * t * t * e
	}

	function Xn(t, e) {
		return t * t * t * e
	}

	function Yn(t, e, n, i, r) {
		return jn(t, e) + Hn(t, n) + Wn(t, i) + Xn(t, r)
	}

	function qn() {
		this.type = "Curve", this.arcLengthDivisions = 200
	}

	function Zn(t, e) {
		qn.call(this), this.type = "LineCurve", this.v1 = t || new n, this.v2 = e || new n
	}

	function Jn() {
		qn.call(this), this.type = "CurvePath", this.curves = [], this.autoClose = !1
	}

	function Kn(t, e, n, i, r, a, o, s) {
		qn.call(this), this.type = "EllipseCurve", this.aX = t || 0, this.aY = e || 0, this.xRadius = n || 1, this.yRadius = i || 1, this.aStartAngle = r || 0, this.aEndAngle = a || 2 * Math.PI, this.aClockwise = o || !1, this.aRotation = s || 0
	}

	function Qn(t) {
		qn.call(this), this.type = "SplineCurve", this.points = t || []
	}

	function $n(t, e, i, r) {
		qn.call(this), this.type = "CubicBezierCurve", this.v0 = t || new n, this.v1 = e || new n, this.v2 = i || new n, this.v3 = r || new n
	}

	function ti(t, e, i) {
		qn.call(this), this.type = "QuadraticBezierCurve", this.v0 = t || new n, this.v1 = e || new n, this.v2 = i || new n
	}

	function ei(t) {
		Jn.call(this), this.type = "Path", this.currentPoint = new n, t && this.setFromPoints(t)
	}

	function ni(t) {
		ei.call(this, t), this.type = "Shape", this.holes = []
	}

	function ii() {
		this.type = "ShapePath", this.subPaths = [], this.currentPath = null
	}

	function ri(t) {
		this.type = "Font", this.data = t
	}

	function ai(t) {
		this.manager = void 0 !== t ? t : io
	}

	function oi(t, e, n) {
		var i = n || si.parseTrackName(e);
		this._targetGroup = t, this._bindings = t.subscribe_(e, i)
	}

	function si(t, e, n) {
		this.path = e, this.parsedPath = n || si.parseTrackName(e), this.node = si.findNode(t, this.parsedPath.nodeName) || t, this.rootNode = t
	}

	function li() {
		this.uuid = Oa.generateUUID(), this._objects = Array.prototype.slice.call(arguments), this.nCachedObjects_ = 0;
		var t = {};
		this._indicesByUUID = t;
		for(var e = 0, n = arguments.length; e !== n; ++e) t[arguments[e].uuid] = e;
		this._paths = [], this._parsedPaths = [], this._bindings = [], this._bindingsIndicesByPath = {};
		var i = this;
		this.stats = {
			objects: {
				get total() {
					return i._objects.length
				},
				get inUse() {
					return this.total - i.nCachedObjects_
				}
			},
			get bindingsPerObject() {
				return i._bindings.length
			}
		}
	}

	function ci(t) {
		"string" == typeof t && (t = arguments[1]), this.value = t
	}

	function hi() {
		Et.call(this), this.type = "InstancedBufferGeometry", this.maxInstancedCount = void 0
	}

	function ui(t, e, n, i) {
		this.uuid = Oa.generateUUID(), this.data = t, this.itemSize = e, this.offset = n, this.normalized = !0 === i
	}

	function fi(t, e) {
		this.uuid = Oa.generateUUID(), this.array = t, this.stride = e, this.count = void 0 !== t ? t.length / e : 0, this.dynamic = !1, this.updateRange = {
			offset: 0,
			count: -1
		}, this.onUploadCallback = function() {}, this.version = 0
	}

	function pi(t, e, n) {
		fi.call(this, t, e), this.meshPerAttribute = n || 1
	}

	function di(t, e, n) {
		dt.call(this, t, e), this.meshPerAttribute = n || 1
	}

	function mi(t, e, n, i) {
		this.ray = new Rt(t, e), this.near = n || 0, this.far = i || 1 / 0, this.params = {
			Mesh: {},
			Line: {},
			Points: {
				threshold: 1
			},
			Sprite: {}
		}, Object.defineProperties(this.params, {
			PointCloud: {
				get: function() {
					return this.Points
				}
			}
		})
	}

	function gi(t, e) {
		return t.distance - e.distance
	}

	function vi(t, e, n, i) {
		if(!1 !== t.visible && (t.raycast(e, n), !0 === i))
			for(var r = t.children, a = 0, o = r.length; a < o; a++) vi(r[a], e, n, !0)
	}

	function _i(t) {
		this.autoStart = void 0 === t || t, this.startTime = 0, this.oldTime = 0, this.elapsedTime = 0, this.running = !1
	}

	function yi(t, e, n) {
		return this.radius = void 0 !== t ? t : 1, this.phi = void 0 !== e ? e : 0, this.theta = void 0 !== n ? n : 0, this
	}

	function xi(t, e, n) {
		return this.radius = void 0 !== t ? t : 1, this.theta = void 0 !== e ? e : 0, this.y = void 0 !== n ? n : 0, this
	}

	function bi(t, e) {
		this.object = t, void 0 === e && (e = 16776960);
		var n = new Uint16Array([0, 1, 1, 2, 2, 3, 3, 0, 4, 5, 5, 6, 6, 7, 7, 4, 0, 4, 1, 5, 2, 6, 3, 7]),
			i = new Float32Array(24),
			r = new Et;
		r.setIndex(new dt(n, 1)), r.addAttribute("position", new dt(i, 3)), Ce.call(this, r, new Ae({
			color: e
		})), this.matrixAutoUpdate = !1, this.update()
	}

	function wi(t, e) {
		this.type = "Box3Helper", this.box = t;
		var n = void 0 !== e ? e : 16776960,
			i = new Uint16Array([0, 1, 1, 2, 2, 3, 3, 0, 4, 5, 5, 6, 6, 7, 7, 4, 0, 4, 1, 5, 2, 6, 3, 7]),
			r = [1, 1, 1, -1, 1, 1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1],
			a = new Et;
		a.setIndex(new dt(i, 1)), a.addAttribute("position", new wt(r, 3)), Ce.call(this, a, new Ae({
			color: n
		})), this.geometry.computeBoundingSphere()
	}

	function Mi(t, e, n) {
		this.type = "pr", this.plane = t, this.size = void 0 === e ? 1 : e;
		var i = void 0 !== n ? n : 16776960,
			r = [1, -1, 1, -1, 1, 1, -1, -1, 1, 1, 1, 1, -1, 1, 1, -1, -1, 1, 1, -1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0],
			a = new Et;
		a.addAttribute("position", new wt(r, 3)), a.computeBoundingSphere(), Le.call(this, a, new Ae({
			color: i
		}));
		var o = [1, 1, 1, -1, 1, 1, -1, -1, 1, 1, 1, 1, -1, -1, 1, 1, -1, 1],
			s = new Et;
		s.addAttribute("position", new wt(o, 3)), s.computeBoundingSphere(), this.add(new Dt(s, new Pt({
			color: i,
			opacity: .2,
			transparent: !0,
			depthWrite: !1
		})))
	}

	function Si(t, e, n, i, r, a) {
		ct.call(this), void 0 === i && (i = 16776960), void 0 === n && (n = 1), void 0 === r && (r = .2 * n), void 0 === a && (a = .2 * r), void 0 === ho && ((ho = new Et).addAttribute("position", new wt([0, 0, 0, 0, 1, 0], 3)), (uo = new We(0, .5, 1, 5, 1)).translate(0, -.5, 0)), this.position.copy(e), this.line = new Le(ho, new Ae({
			color: i
		})), this.line.matrixAutoUpdate = !1, this.add(this.line), this.cone = new Dt(uo, new Pt({
			color: i
		})), this.cone.matrixAutoUpdate = !1, this.add(this.cone), this.setDirection(t), this.setLength(n, r, a)
	}

	function Gi(t) {
		var e = [0, 0, 0, t = t || 1, 0, 0, 0, 0, 0, 0, t, 0, 0, 0, 0, 0, 0, t],
			n = [1, 0, 0, 1, .6, 0, 0, 1, 0, .6, 1, 0, 0, 0, 1, 0, .6, 1],
			i = new Et;
		i.addAttribute("position", new wt(e, 3)), i.addAttribute("color", new wt(n, 3));
		var r = new Ae({
			vertexColors: Xi
		});
		Ce.call(this, i, r)
	}

	function Ei() {
		function t(t, a, o, s) {
			e = t, n = o, i = -3 * t + 3 * a - 2 * o - s, r = 2 * t - 2 * a + o + s
		}
		var e = 0,
			n = 0,
			i = 0,
			r = 0;
		return {
			initCatmullRom: function(e, n, i, r, a) {
				t(n, i, a * (i - e), a * (r - n))
			},
			initNonuniformCatmullRom: function(e, n, i, r, a, o, s) {
				var l = (n - e) / a - (i - e) / (a + o) + (i - n) / o,
					c = (i - n) / o - (r - n) / (o + s) + (r - i) / s;
				t(n, i, l *= o, c *= o)
			},
			calc: function(t) {
				var a = t * t;
				return e + n * t + i * a + r * (a * t)
			}
		}
	}

	function Ti(t, e, n, i) {
		qn.call(this), this.type = "CatmullRomCurve3", this.points = t || [], this.closed = e || !1, this.curveType = n || "centripetal", this.tension = i || .5
	}

	function Ai(t, e, n, i) {
		qn.call(this), this.type = "CubicBezierCurve3", this.v0 = t || new a, this.v1 = e || new a, this.v2 = n || new a, this.v3 = i || new a
	}

	function Li(t, e, n) {
		qn.call(this), this.type = "QuadraticBezierCurve3", this.v0 = t || new a, this.v1 = e || new a, this.v2 = n || new a
	}

	function Ci(t, e) {
		qn.call(this), this.type = "LineCurve3", this.v1 = t || new a, this.v2 = e || new a
	}

	function Pi(t, e, n, i, r, a) {
		Kn.call(this, t, e, n, n, i, r, a), this.type = "ArcCurve"
	}

	function Ii(t) {
		Ti.call(this, t), this.type = "catmullrom", this.closed = !0
	}

	function Ri(t) {
		Ti.call(this, t), this.type = "catmullrom"
	}

	function Oi(t) {
		Ti.call(this, t), this.type = "catmullrom"
	}
	void 0 === Number.EPSILON && (Number.EPSILON = Math.pow(2, -52)), void 0 === Number.isInteger && (Number.isInteger = function(t) {
		return "number" == typeof t && isFinite(t) && Math.floor(t) === t
	}), void 0 === Math.sign && (Math.sign = function(t) {
		return t < 0 ? -1 : t > 0 ? 1 : +t
	}), "name" in Function.prototype == !1 && Object.defineProperty(Function.prototype, "name", {
		get: function() {
			return this.toString().match(/^\s*function\s*([^\(\s]*)/)[1]
		}
	}), void 0 === Object.assign && (Object.assign = function(t) {
		for(var e = Object(t), n = 1; n < arguments.length; n++) {
			var i = arguments[n];
			if(void 0 !== i && null !== i)
				for(var r in i) Object.prototype.hasOwnProperty.call(i, r) && (e[r] = i[r])
		}
		return e
	}), Object.assign(e.prototype, {
		addEventListener: function(t, e) {
			void 0 === this._listeners && (this._listeners = {});
			var n = this._listeners;
			void 0 === n[t] && (n[t] = []), -1 === n[t].indexOf(e) && n[t].push(e)
		},
		hasEventListener: function(t, e) {
			if(void 0 === this._listeners) return !1;
			var n = this._listeners;
			return void 0 !== n[t] && -1 !== n[t].indexOf(e)
		},
		removeEventListener: function(t, e) {
			if(void 0 !== this._listeners) {
				var n = this._listeners[t];
				if(void 0 !== n) {
					var i = n.indexOf(e); - 1 !== i && n.splice(i, 1)
				}
			}
		},
		dispatchEvent: function(t) {
			if(void 0 !== this._listeners) {
				var e = this._listeners[t.type];
				if(void 0 !== e) {
					t.target = this;
					for(var n = e.slice(0), i = 0, r = n.length; i < r; i++) n[i].call(this, t)
				}
			}
		}
	});
	var Ni = {
			LEFT: 0,
			MIDDLE: 1,
			RIGHT: 2
		},
		Di = 0,
		zi = 1,
		Ui = 2,
		Fi = 0,
		ki = 1,
		Bi = 2,
		Vi = 0,
		ji = 1,
		Hi = 2,
		Wi = 0,
		Xi = 2,
		Yi = 0,
		qi = 1,
		Zi = 2,
		Ji = 3,
		Ki = 4,
		Qi = 5,
		$i = 100,
		tr = 101,
		er = 102,
		nr = 103,
		ir = 104,
		rr = 200,
		ar = 201,
		or = 202,
		sr = 203,
		lr = 204,
		cr = 205,
		hr = 206,
		ur = 207,
		fr = 208,
		pr = 209,
		dr = 210,
		mr = 0,
		gr = 1,
		vr = 2,
		_r = 3,
		yr = 4,
		xr = 5,
		br = 6,
		wr = 7,
		Mr = 0,
		Sr = 1,
		Gr = 2,
		Er = 0,
		Tr = 1,
		Ar = 2,
		Lr = 3,
		Cr = 4,
		Pr = 301,
		Ir = 302,
		Rr = 303,
		Or = 304,
		Nr = 305,
		Dr = 306,
		zr = 307,
		Ur = 1e3,
		Fr = 1001,
		kr = 1002,
		Br = 1003,
		Vr = 1004,
		jr = 1005,
		Hr = 1006,
		Wr = 1007,
		Xr = 1008,
		Yr = 1009,
		qr = 1010,
		Zr = 1011,
		Jr = 1012,
		Kr = 1013,
		Qr = 1014,
		$r = 1015,
		ta = 1016,
		ea = 1017,
		na = 1018,
		ia = 1019,
		ra = 1020,
		aa = 1021,
		oa = 1022,
		sa = 1023,
		la = 1024,
		ca = 1025,
		ha = sa,
		ua = 1026,
		fa = 1027,
		pa = 2001,
		da = 2002,
		ma = 2003,
		ga = 2004,
		va = 2100,
		_a = 2101,
		ya = 2102,
		xa = 2103,
		ba = 2151,
		wa = 0,
		Ma = 1,
		Sa = 2,
		Ga = 3e3,
		Ea = 3001,
		Ta = 3007,
		Aa = 3002,
		La = 3004,
		Ca = 3005,
		Pa = 3006,
		Ia = 3200,
		Ra = 3201,
		Oa = {
			DEG2RAD: Math.PI / 180,
			RAD2DEG: 180 / Math.PI,
			generateUUID: function() {
				for(var t = [], e = 0; e < 256; e++) t[e] = (e < 16 ? "0" : "") + e.toString(16).toUpperCase();
				return function() {
					var e = 4294967295 * Math.random() | 0,
						n = 4294967295 * Math.random() | 0,
						i = 4294967295 * Math.random() | 0,
						r = 4294967295 * Math.random() | 0;
					return t[255 & e] + t[e >> 8 & 255] + t[e >> 16 & 255] + t[e >> 24 & 255] + "-" + t[255 & n] + t[n >> 8 & 255] + "-" + t[n >> 16 & 15 | 64] + t[n >> 24 & 255] + "-" + t[63 & i | 128] + t[i >> 8 & 255] + "-" + t[i >> 16 & 255] + t[i >> 24 & 255] + t[255 & r] + t[r >> 8 & 255] + t[r >> 16 & 255] + t[r >> 24 & 255]
				}
			}(),
			clamp: function(t, e, n) {
				return Math.max(e, Math.min(n, t))
			},
			euclideanModulo: function(t, e) {
				return(t % e + e) % e
			},
			mapLinear: function(t, e, n, i, r) {
				return i + (t - e) * (r - i) / (n - e)
			},
			lerp: function(t, e, n) {
				return(1 - n) * t + n * e
			},
			smoothstep: function(t, e, n) {
				return t <= e ? 0 : t >= n ? 1 : (t = (t - e) / (n - e)) * t * (3 - 2 * t)
			},
			smootherstep: function(t, e, n) {
				return t <= e ? 0 : t >= n ? 1 : (t = (t - e) / (n - e)) * t * t * (t * (6 * t - 15) + 10)
			},
			randInt: function(t, e) {
				return t + Math.floor(Math.random() * (e - t + 1))
			},
			randFloat: function(t, e) {
				return t + Math.random() * (e - t)
			},
			randFloatSpread: function(t) {
				return t * (.5 - Math.random())
			},
			degToRad: function(t) {
				return t * Oa.DEG2RAD
			},
			radToDeg: function(t) {
				return t * Oa.RAD2DEG
			},
			isPowerOfTwo: function(t) {
				return 0 == (t & t - 1) && 0 !== t
			},
			ceilPowerOfTwo: function(t) {
				return Math.pow(2, Math.ceil(Math.log(t) / Math.LN2))
			},
			floorPowerOfTwo: function(t) {
				return Math.pow(2, Math.floor(Math.log(t) / Math.LN2))
			}
		};
	Object.defineProperties(n.prototype, {
		width: {
			get: function() {
				return this.x
			},
			set: function(t) {
				this.x = t
			}
		},
		height: {
			get: function() {
				return this.y
			},
			set: function(t) {
				this.y = t
			}
		}
	}), Object.assign(n.prototype, {
		isVector2: !0,
		set: function(t, e) {
			return this.x = t, this.y = e, this
		},
		setScalar: function(t) {
			return this.x = t, this.y = t, this
		},
		setX: function(t) {
			return this.x = t, this
		},
		setY: function(t) {
			return this.y = t, this
		},
		setComponent: function(t, e) {
			switch(t) {
				case 0:
					this.x = e;
					break;
				case 1:
					this.y = e
			}
			return this
		},
		getComponent: function(t) {
			switch(t) {
				case 0:
					return this.x;
				case 1:
					return this.y
			}
		},
		clone: function() {
			return new this.constructor(this.x, this.y)
		},
		copy: function(t) {
			return this.x = t.x, this.y = t.y, this
		},
		add: function(t, e) {
			return void 0 !== e ? this.addVectors(t, e) : (this.x += t.x, this.y += t.y, this)
		},
		addScalar: function(t) {
			return this.x += t, this.y += t, this
		},
		addVectors: function(t, e) {
			return this.x = t.x + e.x, this.y = t.y + e.y, this
		},
		addScaledVector: function(t, e) {
			return this.x += t.x * e, this.y += t.y * e, this
		},
		sub: function(t, e) {
			return void 0 !== e ? this.subVectors(t, e) : (this.x -= t.x, this.y -= t.y, this)
		},
		subScalar: function(t) {
			return this.x -= t, this.y -= t, this
		},
		subVectors: function(t, e) {
			return this.x = t.x - e.x, this.y = t.y - e.y, this
		},
		multiply: function(t) {
			return this.x *= t.x, this.y *= t.y, this
		},
		multiplyScalar: function(t) {
			return this.x *= t, this.y *= t, this
		},
		divide: function(t) {
			return this.x /= t.x, this.y /= t.y, this
		},
		divideScalar: function(t) {
			return this.multiplyScalar(1 / t)
		},
		applyMatrix3: function(t) {
			var e = this.x,
				n = this.y,
				i = t.elements;
			return this.x = i[0] * e + i[3] * n + i[6], this.y = i[1] * e + i[4] * n + i[7], this
		},
		min: function(t) {
			return this.x = Math.min(this.x, t.x), this.y = Math.min(this.y, t.y), this
		},
		max: function(t) {
			return this.x = Math.max(this.x, t.x), this.y = Math.max(this.y, t.y), this
		},
		clamp: function(t, e) {
			return this.x = Math.max(t.x, Math.min(e.x, this.x)), this.y = Math.max(t.y, Math.min(e.y, this.y)), this
		},
		clampScalar: function() {
			var t = new n,
				e = new n;
			return function(n, i) {
				return t.set(n, n), e.set(i, i), this.clamp(t, e)
			}
		}(),
		clampLength: function(t, e) {
			var n = this.length();
			return this.divideScalar(n || 1).multiplyScalar(Math.max(t, Math.min(e, n)))
		},
		floor: function() {
			return this.x = Math.floor(this.x), this.y = Math.floor(this.y), this
		},
		ceil: function() {
			return this.x = Math.ceil(this.x), this.y = Math.ceil(this.y), this
		},
		round: function() {
			return this.x = Math.round(this.x), this.y = Math.round(this.y), this
		},
		roundToZero: function() {
			return this.x = this.x < 0 ? Math.ceil(this.x) : Math.floor(this.x), this.y = this.y < 0 ? Math.ceil(this.y) : Math.floor(this.y), this
		},
		negate: function() {
			return this.x = -this.x, this.y = -this.y, this
		},
		dot: function(t) {
			return this.x * t.x + this.y * t.y
		},
		lengthSq: function() {
			return this.x * this.x + this.y * this.y
		},
		length: function() {
			return Math.sqrt(this.x * this.x + this.y * this.y)
		},
		manhattanLength: function() {
			return Math.abs(this.x) + Math.abs(this.y)
		},
		normalize: function() {
			return this.divideScalar(this.length() || 1)
		},
		angle: function() {
			var t = Math.atan2(this.y, this.x);
			return t < 0 && (t += 2 * Math.PI), t
		},
		distanceTo: function(t) {
			return Math.sqrt(this.distanceToSquared(t))
		},
		distanceToSquared: function(t) {
			var e = this.x - t.x,
				n = this.y - t.y;
			return e * e + n * n
		},
		manhattanDistanceTo: function(t) {
			return Math.abs(this.x - t.x) + Math.abs(this.y - t.y)
		},
		setLength: function(t) {
			return this.normalize().multiplyScalar(t)
		},
		lerp: function(t, e) {
			return this.x += (t.x - this.x) * e, this.y += (t.y - this.y) * e, this
		},
		lerpVectors: function(t, e, n) {
			return this.subVectors(e, t).multiplyScalar(n).add(t)
		},
		equals: function(t) {
			return t.x === this.x && t.y === this.y
		},
		fromArray: function(t, e) {
			return void 0 === e && (e = 0), this.x = t[e], this.y = t[e + 1], this
		},
		toArray: function(t, e) {
			return void 0 === t && (t = []), void 0 === e && (e = 0), t[e] = this.x, t[e + 1] = this.y, t
		},
		fromBufferAttribute: function(t, e, n) {
			return this.x = t.getX(e), this.y = t.getY(e), this
		},
		rotateAround: function(t, e) {
			var n = Math.cos(e),
				i = Math.sin(e),
				r = this.x - t.x,
				a = this.y - t.y;
			return this.x = r * n - a * i + t.x, this.y = r * i + a * n + t.y, this
		}
	}), Object.assign(i.prototype, {
		isMatrix4: !0,
		set: function(t, e, n, i, r, a, o, s, l, c, h, u, f, p, d, m) {
			var g = this.elements;
			return g[0] = t, g[4] = e, g[8] = n, g[12] = i, g[1] = r, g[5] = a, g[9] = o, g[13] = s, g[2] = l, g[6] = c, g[10] = h, g[14] = u, g[3] = f, g[7] = p, g[11] = d, g[15] = m, this
		},
		identity: function() {
			return this.set(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1), this
		},
		clone: function() {
			return(new i).fromArray(this.elements)
		},
		copy: function(t) {
			var e = this.elements,
				n = t.elements;
			return e[0] = n[0], e[1] = n[1], e[2] = n[2], e[3] = n[3], e[4] = n[4], e[5] = n[5], e[6] = n[6], e[7] = n[7], e[8] = n[8], e[9] = n[9], e[10] = n[10], e[11] = n[11], e[12] = n[12], e[13] = n[13], e[14] = n[14], e[15] = n[15], this
		},
		copyPosition: function(t) {
			var e = this.elements,
				n = t.elements;
			return e[12] = n[12], e[13] = n[13], e[14] = n[14], this
		},
		extractBasis: function(t, e, n) {
			return t.setFromMatrixColumn(this, 0), e.setFromMatrixColumn(this, 1), n.setFromMatrixColumn(this, 2), this
		},
		makeBasis: function(t, e, n) {
			return this.set(t.x, e.x, n.x, 0, t.y, e.y, n.y, 0, t.z, e.z, n.z, 0, 0, 0, 0, 1), this
		},
		extractRotation: function() {
			var t = new a;
			return function(e) {
				var n = this.elements,
					i = e.elements,
					r = 1 / t.setFromMatrixColumn(e, 0).length(),
					a = 1 / t.setFromMatrixColumn(e, 1).length(),
					o = 1 / t.setFromMatrixColumn(e, 2).length();
				return n[0] = i[0] * r, n[1] = i[1] * r, n[2] = i[2] * r, n[4] = i[4] * a, n[5] = i[5] * a, n[6] = i[6] * a, n[8] = i[8] * o, n[9] = i[9] * o, n[10] = i[10] * o, this
			}
		}(),
		makeRotationFromEuler: function(t) {
			!t || t.isEuler;
			var e = this.elements,
				n = t.x,
				i = t.y,
				r = t.z,
				a = Math.cos(n),
				o = Math.sin(n),
				s = Math.cos(i),
				l = Math.sin(i),
				c = Math.cos(r),
				h = Math.sin(r);
			if("XYZ" === t.order) {
				var u = a * c,
					f = a * h,
					p = o * c,
					d = o * h;
				e[0] = s * c, e[4] = -s * h, e[8] = l, e[1] = f + p * l, e[5] = u - d * l, e[9] = -o * s, e[2] = d - u * l, e[6] = p + f * l, e[10] = a * s
			} else if("YXZ" === t.order) {
				var m = s * c,
					g = s * h,
					v = l * c,
					_ = l * h;
				e[0] = m + _ * o, e[4] = v * o - g, e[8] = a * l, e[1] = a * h, e[5] = a * c, e[9] = -o, e[2] = g * o - v, e[6] = _ + m * o, e[10] = a * s
			} else if("ZXY" === t.order) {
				var m = s * c,
					g = s * h,
					v = l * c,
					_ = l * h;
				e[0] = m - _ * o, e[4] = -a * h, e[8] = v + g * o, e[1] = g + v * o, e[5] = a * c, e[9] = _ - m * o, e[2] = -a * l, e[6] = o, e[10] = a * s
			} else if("ZYX" === t.order) {
				var u = a * c,
					f = a * h,
					p = o * c,
					d = o * h;
				e[0] = s * c, e[4] = p * l - f, e[8] = u * l + d, e[1] = s * h, e[5] = d * l + u, e[9] = f * l - p, e[2] = -l, e[6] = o * s, e[10] = a * s
			} else if("YZX" === t.order) {
				var y = a * s,
					x = a * l,
					b = o * s,
					w = o * l;
				e[0] = s * c, e[4] = w - y * h, e[8] = b * h + x, e[1] = h, e[5] = a * c, e[9] = -o * c, e[2] = -l * c, e[6] = x * h + b, e[10] = y - w * h
			} else if("XZY" === t.order) {
				var y = a * s,
					x = a * l,
					b = o * s,
					w = o * l;
				e[0] = s * c, e[4] = -h, e[8] = l * c, e[1] = y * h + w, e[5] = a * c, e[9] = x * h - b, e[2] = b * h - x, e[6] = o * c, e[10] = w * h + y
			}
			return e[3] = 0, e[7] = 0, e[11] = 0, e[12] = 0, e[13] = 0, e[14] = 0, e[15] = 1, this
		},
		makeRotationFromQuaternion: function(t) {
			var e = this.elements,
				n = t._x,
				i = t._y,
				r = t._z,
				a = t._w,
				o = n + n,
				s = i + i,
				l = r + r,
				c = n * o,
				h = n * s,
				u = n * l,
				f = i * s,
				p = i * l,
				d = r * l,
				m = a * o,
				g = a * s,
				v = a * l;
			return e[0] = 1 - (f + d), e[4] = h - v, e[8] = u + g, e[1] = h + v, e[5] = 1 - (c + d), e[9] = p - m, e[2] = u - g, e[6] = p + m, e[10] = 1 - (c + f), e[3] = 0, e[7] = 0, e[11] = 0, e[12] = 0, e[13] = 0, e[14] = 0, e[15] = 1, this
		},
		lookAt: function() {
			var t = new a,
				e = new a,
				n = new a;
			return function(i, r, a) {
				var o = this.elements;
				return n.subVectors(i, r), 0 === n.lengthSq() && (n.z = 1), n.normalize(), t.crossVectors(a, n), 0 === t.lengthSq() && (1 === Math.abs(a.z) ? n.x += 1e-4 : n.z += 1e-4, n.normalize(), t.crossVectors(a, n)), t.normalize(), e.crossVectors(n, t), o[0] = t.x, o[4] = e.x, o[8] = n.x, o[1] = t.y, o[5] = e.y, o[9] = n.y, o[2] = t.z, o[6] = e.z, o[10] = n.z, this
			}
		}(),
		multiply: function(t, e) {
			return void 0 !== e ? this.multiplyMatrices(t, e) : this.multiplyMatrices(this, t)
		},
		premultiply: function(t) {
			return this.multiplyMatrices(t, this)
		},
		multiplyMatrices: function(t, e) {
			var n = t.elements,
				i = e.elements,
				r = this.elements,
				a = n[0],
				o = n[4],
				s = n[8],
				l = n[12],
				c = n[1],
				h = n[5],
				u = n[9],
				f = n[13],
				p = n[2],
				d = n[6],
				m = n[10],
				g = n[14],
				v = n[3],
				_ = n[7],
				y = n[11],
				x = n[15],
				b = i[0],
				w = i[4],
				M = i[8],
				S = i[12],
				G = i[1],
				E = i[5],
				T = i[9],
				A = i[13],
				L = i[2],
				C = i[6],
				P = i[10],
				I = i[14],
				R = i[3],
				O = i[7],
				N = i[11],
				D = i[15];
			return r[0] = a * b + o * G + s * L + l * R, r[4] = a * w + o * E + s * C + l * O, r[8] = a * M + o * T + s * P + l * N, r[12] = a * S + o * A + s * I + l * D, r[1] = c * b + h * G + u * L + f * R, r[5] = c * w + h * E + u * C + f * O, r[9] = c * M + h * T + u * P + f * N, r[13] = c * S + h * A + u * I + f * D, r[2] = p * b + d * G + m * L + g * R, r[6] = p * w + d * E + m * C + g * O, r[10] = p * M + d * T + m * P + g * N, r[14] = p * S + d * A + m * I + g * D, r[3] = v * b + _ * G + y * L + x * R, r[7] = v * w + _ * E + y * C + x * O, r[11] = v * M + _ * T + y * P + x * N, r[15] = v * S + _ * A + y * I + x * D, this
		},
		multiplyScalar: function(t) {
			var e = this.elements;
			return e[0] *= t, e[4] *= t, e[8] *= t, e[12] *= t, e[1] *= t, e[5] *= t, e[9] *= t, e[13] *= t, e[2] *= t, e[6] *= t, e[10] *= t, e[14] *= t, e[3] *= t, e[7] *= t, e[11] *= t, e[15] *= t, this
		},
		applyToBufferAttribute: function() {
			var t = new a;
			return function(e) {
				for(var n = 0, i = e.count; n < i; n++) t.x = e.getX(n), t.y = e.getY(n), t.z = e.getZ(n), t.applyMatrix4(this), e.setXYZ(n, t.x, t.y, t.z);
				return e
			}
		}(),
		determinant: function() {
			var t = this.elements,
				e = t[0],
				n = t[4],
				i = t[8],
				r = t[12],
				a = t[1],
				o = t[5],
				s = t[9],
				l = t[13],
				c = t[2],
				h = t[6],
				u = t[10],
				f = t[14];
			return t[3] * (+r * s * h - i * l * h - r * o * u + n * l * u + i * o * f - n * s * f) + t[7] * (+e * s * f - e * l * u + r * a * u - i * a * f + i * l * c - r * s * c) + t[11] * (+e * l * h - e * o * f - r * a * h + n * a * f + r * o * c - n * l * c) + t[15] * (-i * o * c - e * s * h + e * o * u + i * a * h - n * a * u + n * s * c)
		},
		transpose: function() {
			var t, e = this.elements;
			return t = e[1], e[1] = e[4], e[4] = t, t = e[2], e[2] = e[8], e[8] = t, t = e[6], e[6] = e[9], e[9] = t, t = e[3], e[3] = e[12], e[12] = t, t = e[7], e[7] = e[13], e[13] = t, t = e[11], e[11] = e[14], e[14] = t, this
		},
		setPosition: function(t) {
			var e = this.elements;
			return e[12] = t.x, e[13] = t.y, e[14] = t.z, this
		},
		getInverse: function(t, e) {
			var n = this.elements,
				i = t.elements,
				r = i[0],
				a = i[1],
				o = i[2],
				s = i[3],
				l = i[4],
				c = i[5],
				h = i[6],
				u = i[7],
				f = i[8],
				p = i[9],
				d = i[10],
				m = i[11],
				g = i[12],
				v = i[13],
				_ = i[14],
				y = i[15],
				x = p * _ * u - v * d * u + v * h * m - c * _ * m - p * h * y + c * d * y,
				b = g * d * u - f * _ * u - g * h * m + l * _ * m + f * h * y - l * d * y,
				w = f * v * u - g * p * u + g * c * m - l * v * m - f * c * y + l * p * y,
				M = g * p * h - f * v * h - g * c * d + l * v * d + f * c * _ - l * p * _,
				S = r * x + a * b + o * w + s * M;
			if(0 === S) return this.identity();
			var G = 1 / S;
			return n[0] = x * G, n[1] = (v * d * s - p * _ * s - v * o * m + a * _ * m + p * o * y - a * d * y) * G, n[2] = (c * _ * s - v * h * s + v * o * u - a * _ * u - c * o * y + a * h * y) * G, n[3] = (p * h * s - c * d * s - p * o * u + a * d * u + c * o * m - a * h * m) * G, n[4] = b * G, n[5] = (f * _ * s - g * d * s + g * o * m - r * _ * m - f * o * y + r * d * y) * G, n[6] = (g * h * s - l * _ * s - g * o * u + r * _ * u + l * o * y - r * h * y) * G, n[7] = (l * d * s - f * h * s + f * o * u - r * d * u - l * o * m + r * h * m) * G, n[8] = w * G, n[9] = (g * p * s - f * v * s - g * a * m + r * v * m + f * a * y - r * p * y) * G, n[10] = (l * v * s - g * c * s + g * a * u - r * v * u - l * a * y + r * c * y) * G, n[11] = (f * c * s - l * p * s - f * a * u + r * p * u + l * a * m - r * c * m) * G, n[12] = M * G, n[13] = (f * v * o - g * p * o + g * a * d - r * v * d - f * a * _ + r * p * _) * G, n[14] = (g * c * o - l * v * o - g * a * h + r * v * h + l * a * _ - r * c * _) * G, n[15] = (l * p * o - f * c * o + f * a * h - r * p * h - l * a * d + r * c * d) * G, this
		},
		scale: function(t) {
			var e = this.elements,
				n = t.x,
				i = t.y,
				r = t.z;
			return e[0] *= n, e[4] *= i, e[8] *= r, e[1] *= n, e[5] *= i, e[9] *= r, e[2] *= n, e[6] *= i, e[10] *= r, e[3] *= n, e[7] *= i, e[11] *= r, this
		},
		getMaxScaleOnAxis: function() {
			var t = this.elements,
				e = t[0] * t[0] + t[1] * t[1] + t[2] * t[2],
				n = t[4] * t[4] + t[5] * t[5] + t[6] * t[6],
				i = t[8] * t[8] + t[9] * t[9] + t[10] * t[10];
			return Math.sqrt(Math.max(e, n, i))
		},
		makeTranslation: function(t, e, n) {
			return this.set(1, 0, 0, t, 0, 1, 0, e, 0, 0, 1, n, 0, 0, 0, 1), this
		},
		makeRotationX: function(t) {
			var e = Math.cos(t),
				n = Math.sin(t);
			return this.set(1, 0, 0, 0, 0, e, -n, 0, 0, n, e, 0, 0, 0, 0, 1), this
		},
		makeRotationY: function(t) {
			var e = Math.cos(t),
				n = Math.sin(t);
			return this.set(e, 0, n, 0, 0, 1, 0, 0, -n, 0, e, 0, 0, 0, 0, 1), this
		},
		makeRotationZ: function(t) {
			var e = Math.cos(t),
				n = Math.sin(t);
			return this.set(e, -n, 0, 0, n, e, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1), this
		},
		makeRotationAxis: function(t, e) {
			var n = Math.cos(e),
				i = Math.sin(e),
				r = 1 - n,
				a = t.x,
				o = t.y,
				s = t.z,
				l = r * a,
				c = r * o;
			return this.set(l * a + n, l * o - i * s, l * s + i * o, 0, l * o + i * s, c * o + n, c * s - i * a, 0, l * s - i * o, c * s + i * a, r * s * s + n, 0, 0, 0, 0, 1), this
		},
		makeScale: function(t, e, n) {
			return this.set(t, 0, 0, 0, 0, e, 0, 0, 0, 0, n, 0, 0, 0, 0, 1), this
		},
		makeShear: function(t, e, n) {
			return this.set(1, e, n, 0, t, 1, n, 0, t, e, 1, 0, 0, 0, 0, 1), this
		},
		compose: function(t, e, n) {
			return this.makeRotationFromQuaternion(e), this.scale(n), this.setPosition(t), this
		},
		decompose: function() {
			var t = new a,
				e = new i;
			return function(n, i, r) {
				var a = this.elements,
					o = t.set(a[0], a[1], a[2]).length(),
					s = t.set(a[4], a[5], a[6]).length(),
					l = t.set(a[8], a[9], a[10]).length();
				this.determinant() < 0 && (o = -o), n.x = a[12], n.y = a[13], n.z = a[14], e.copy(this);
				var c = 1 / o,
					h = 1 / s,
					u = 1 / l;
				return e.elements[0] *= c, e.elements[1] *= c, e.elements[2] *= c, e.elements[4] *= h, e.elements[5] *= h, e.elements[6] *= h, e.elements[8] *= u, e.elements[9] *= u, e.elements[10] *= u, i.setFromRotationMatrix(e), r.x = o, r.y = s, r.z = l, this
			}
		}(),
		makePerspective: function(t, e, n, i, r, a) {
			var o = this.elements,
				s = 2 * r / (e - t),
				l = 2 * r / (n - i),
				c = (e + t) / (e - t),
				h = (n + i) / (n - i),
				u = -(a + r) / (a - r),
				f = -2 * a * r / (a - r);
			return o[0] = s, o[4] = 0, o[8] = c, o[12] = 0, o[1] = 0, o[5] = l, o[9] = h, o[13] = 0, o[2] = 0, o[6] = 0, o[10] = u, o[14] = f, o[3] = 0, o[7] = 0, o[11] = -1, o[15] = 0, this
		},
		makeOrthographic: function(t, e, n, i, r, a) {
			var o = this.elements,
				s = 1 / (e - t),
				l = 1 / (n - i),
				c = 1 / (a - r),
				h = (e + t) * s,
				u = (n + i) * l,
				f = (a + r) * c;
			return o[0] = 2 * s, o[4] = 0, o[8] = 0, o[12] = -h, o[1] = 0, o[5] = 2 * l, o[9] = 0, o[13] = -u, o[2] = 0, o[6] = 0, o[10] = -2 * c, o[14] = -f, o[3] = 0, o[7] = 0, o[11] = 0, o[15] = 1, this
		},
		equals: function(t) {
			for(var e = this.elements, n = t.elements, i = 0; i < 16; i++)
				if(e[i] !== n[i]) return !1;
			return !0
		},
		fromArray: function(t, e) {
			void 0 === e && (e = 0);
			for(var n = 0; n < 16; n++) this.elements[n] = t[n + e];
			return this
		},
		toArray: function(t, e) {
			void 0 === t && (t = []), void 0 === e && (e = 0);
			var n = this.elements;
			return t[e] = n[0], t[e + 1] = n[1], t[e + 2] = n[2], t[e + 3] = n[3], t[e + 4] = n[4], t[e + 5] = n[5], t[e + 6] = n[6], t[e + 7] = n[7], t[e + 8] = n[8], t[e + 9] = n[9], t[e + 10] = n[10], t[e + 11] = n[11], t[e + 12] = n[12], t[e + 13] = n[13], t[e + 14] = n[14], t[e + 15] = n[15], t
		}
	}), Object.assign(r, {
		slerp: function(t, e, n, i) {
			return n.copy(t).slerp(e, i)
		},
		slerpFlat: function(t, e, n, i, r, a, o) {
			var s = n[i + 0],
				l = n[i + 1],
				c = n[i + 2],
				h = n[i + 3],
				u = r[a + 0],
				f = r[a + 1],
				p = r[a + 2],
				d = r[a + 3];
			if(h !== d || s !== u || l !== f || c !== p) {
				var m = 1 - o,
					g = s * u + l * f + c * p + h * d,
					v = g >= 0 ? 1 : -1,
					_ = 1 - g * g;
				if(_ > Number.EPSILON) {
					var y = Math.sqrt(_),
						x = Math.atan2(y, g * v);
					m = Math.sin(m * x) / y, o = Math.sin(o * x) / y
				}
				var b = o * v;
				if(s = s * m + u * b, l = l * m + f * b, c = c * m + p * b, h = h * m + d * b, m === 1 - o) {
					var w = 1 / Math.sqrt(s * s + l * l + c * c + h * h);
					s *= w, l *= w, c *= w, h *= w
				}
			}
			t[e] = s, t[e + 1] = l, t[e + 2] = c, t[e + 3] = h
		}
	}), Object.defineProperties(r.prototype, {
		x: {
			get: function() {
				return this._x
			},
			set: function(t) {
				this._x = t, this.onChangeCallback()
			}
		},
		y: {
			get: function() {
				return this._y
			},
			set: function(t) {
				this._y = t, this.onChangeCallback()
			}
		},
		z: {
			get: function() {
				return this._z
			},
			set: function(t) {
				this._z = t, this.onChangeCallback()
			}
		},
		w: {
			get: function() {
				return this._w
			},
			set: function(t) {
				this._w = t, this.onChangeCallback()
			}
		}
	}), Object.assign(r.prototype, {
		set: function(t, e, n, i) {
			return this._x = t, this._y = e, this._z = n, this._w = i, this.onChangeCallback(), this
		},
		clone: function() {
			return new this.constructor(this._x, this._y, this._z, this._w)
		},
		copy: function(t) {
			return this._x = t.x, this._y = t.y, this._z = t.z, this._w = t.w, this.onChangeCallback(), this
		},
		setFromEuler: function(t, e) {
			var n = t._x,
				i = t._y,
				r = t._z,
				a = t.order,
				o = Math.cos,
				s = Math.sin,
				l = o(n / 2),
				c = o(i / 2),
				h = o(r / 2),
				u = s(n / 2),
				f = s(i / 2),
				p = s(r / 2);
			return "XYZ" === a ? (this._x = u * c * h + l * f * p, this._y = l * f * h - u * c * p, this._z = l * c * p + u * f * h, this._w = l * c * h - u * f * p) : "YXZ" === a ? (this._x = u * c * h + l * f * p, this._y = l * f * h - u * c * p, this._z = l * c * p - u * f * h, this._w = l * c * h + u * f * p) : "ZXY" === a ? (this._x = u * c * h - l * f * p, this._y = l * f * h + u * c * p, this._z = l * c * p + u * f * h, this._w = l * c * h - u * f * p) : "ZYX" === a ? (this._x = u * c * h - l * f * p, this._y = l * f * h + u * c * p, this._z = l * c * p - u * f * h, this._w = l * c * h + u * f * p) : "YZX" === a ? (this._x = u * c * h + l * f * p, this._y = l * f * h + u * c * p, this._z = l * c * p - u * f * h, this._w = l * c * h - u * f * p) : "XZY" === a && (this._x = u * c * h - l * f * p, this._y = l * f * h - u * c * p, this._z = l * c * p + u * f * h, this._w = l * c * h + u * f * p), !1 !== e && this.onChangeCallback(), this
		},
		setFromAxisAngle: function(t, e) {
			var n = e / 2,
				i = Math.sin(n);
			return this._x = t.x * i, this._y = t.y * i, this._z = t.z * i, this._w = Math.cos(n), this.onChangeCallback(), this
		},
		setFromRotationMatrix: function(t) {
			var e, n = t.elements,
				i = n[0],
				r = n[4],
				a = n[8],
				o = n[1],
				s = n[5],
				l = n[9],
				c = n[2],
				h = n[6],
				u = n[10],
				f = i + s + u;
			return f > 0 ? (e = .5 / Math.sqrt(f + 1), this._w = .25 / e, this._x = (h - l) * e, this._y = (a - c) * e, this._z = (o - r) * e) : i > s && i > u ? (e = 2 * Math.sqrt(1 + i - s - u), this._w = (h - l) / e, this._x = .25 * e, this._y = (r + o) / e, this._z = (a + c) / e) : s > u ? (e = 2 * Math.sqrt(1 + s - i - u), this._w = (a - c) / e, this._x = (r + o) / e, this._y = .25 * e, this._z = (l + h) / e) : (e = 2 * Math.sqrt(1 + u - i - s), this._w = (o - r) / e, this._x = (a + c) / e, this._y = (l + h) / e, this._z = .25 * e), this.onChangeCallback(), this
		},
		setFromUnitVectors: function() {
			var t, e = new a;
			return function(n, i) {
				return void 0 === e && (e = new a), t = n.dot(i) + 1, t < 1e-6 ? (t = 0, Math.abs(n.x) > Math.abs(n.z) ? e.set(-n.y, n.x, 0) : e.set(0, -n.z, n.y)) : e.crossVectors(n, i), this._x = e.x, this._y = e.y, this._z = e.z, this._w = t, this.normalize()
			}
		}(),
		inverse: function() {
			return this.conjugate().normalize()
		},
		conjugate: function() {
			return this._x *= -1, this._y *= -1, this._z *= -1, this.onChangeCallback(), this
		},
		dot: function(t) {
			return this._x * t._x + this._y * t._y + this._z * t._z + this._w * t._w
		},
		lengthSq: function() {
			return this._x * this._x + this._y * this._y + this._z * this._z + this._w * this._w
		},
		length: function() {
			return Math.sqrt(this._x * this._x + this._y * this._y + this._z * this._z + this._w * this._w)
		},
		normalize: function() {
			var t = this.length();
			return 0 === t ? (this._x = 0, this._y = 0, this._z = 0, this._w = 1) : (t = 1 / t, this._x = this._x * t, this._y = this._y * t, this._z = this._z * t, this._w = this._w * t), this.onChangeCallback(), this
		},
		multiply: function(t, e) {
			return void 0 !== e ? this.multiplyQuaternions(t, e) : this.multiplyQuaternions(this, t)
		},
		premultiply: function(t) {
			return this.multiplyQuaternions(t, this)
		},
		multiplyQuaternions: function(t, e) {
			var n = t._x,
				i = t._y,
				r = t._z,
				a = t._w,
				o = e._x,
				s = e._y,
				l = e._z,
				c = e._w;
			return this._x = n * c + a * o + i * l - r * s, this._y = i * c + a * s + r * o - n * l, this._z = r * c + a * l + n * s - i * o, this._w = a * c - n * o - i * s - r * l, this.onChangeCallback(), this
		},
		slerp: function(t, e) {
			if(0 === e) return this;
			if(1 === e) return this.copy(t);
			var n = this._x,
				i = this._y,
				r = this._z,
				a = this._w,
				o = a * t._w + n * t._x + i * t._y + r * t._z;
			if(o < 0 ? (this._w = -t._w, this._x = -t._x, this._y = -t._y, this._z = -t._z, o = -o) : this.copy(t), o >= 1) return this._w = a, this._x = n, this._y = i, this._z = r, this;
			var s = Math.sqrt(1 - o * o);
			if(Math.abs(s) < .001) return this._w = .5 * (a + this._w), this._x = .5 * (n + this._x), this._y = .5 * (i + this._y), this._z = .5 * (r + this._z), this;
			var l = Math.atan2(s, o),
				c = Math.sin((1 - e) * l) / s,
				h = Math.sin(e * l) / s;
			return this._w = a * c + this._w * h, this._x = n * c + this._x * h, this._y = i * c + this._y * h, this._z = r * c + this._z * h, this.onChangeCallback(), this
		},
		equals: function(t) {
			return t._x === this._x && t._y === this._y && t._z === this._z && t._w === this._w
		},
		fromArray: function(t, e) {
			return void 0 === e && (e = 0), this._x = t[e], this._y = t[e + 1], this._z = t[e + 2], this._w = t[e + 3], this.onChangeCallback(), this
		},
		toArray: function(t, e) {
			return void 0 === t && (t = []), void 0 === e && (e = 0), t[e] = this._x, t[e + 1] = this._y, t[e + 2] = this._z, t[e + 3] = this._w, t
		},
		onChange: function(t) {
			return this.onChangeCallback = t, this
		},
		onChangeCallback: function() {}
	}), Object.assign(a.prototype, {
		isVector3: !0,
		set: function(t, e, n) {
			return this.x = t, this.y = e, this.z = n, this
		},
		setScalar: function(t) {
			return this.x = t, this.y = t, this.z = t, this
		},
		setX: function(t) {
			return this.x = t, this
		},
		setY: function(t) {
			return this.y = t, this
		},
		setZ: function(t) {
			return this.z = t, this
		},
		setComponent: function(t, e) {
			switch(t) {
				case 0:
					this.x = e;
					break;
				case 1:
					this.y = e;
					break;
				case 2:
					this.z = e
			}
			return this
		},
		getComponent: function(t) {
			switch(t) {
				case 0:
					return this.x;
				case 1:
					return this.y;
				case 2:
					return this.z
			}
		},
		clone: function() {
			return new this.constructor(this.x, this.y, this.z)
		},
		copy: function(t) {
			return this.x = t.x, this.y = t.y, this.z = t.z, this
		},
		add: function(t, e) {
			return void 0 !== e ? this.addVectors(t, e) : (this.x += t.x, this.y += t.y, this.z += t.z, this)
		},
		addScalar: function(t) {
			return this.x += t, this.y += t, this.z += t, this
		},
		addVectors: function(t, e) {
			return this.x = t.x + e.x, this.y = t.y + e.y, this.z = t.z + e.z, this
		},
		addScaledVector: function(t, e) {
			return this.x += t.x * e, this.y += t.y * e, this.z += t.z * e, this
		},
		sub: function(t, e) {
			return void 0 !== e ? this.subVectors(t, e) : (this.x -= t.x, this.y -= t.y, this.z -= t.z, this)
		},
		subScalar: function(t) {
			return this.x -= t, this.y -= t, this.z -= t, this
		},
		subVectors: function(t, e) {
			return this.x = t.x - e.x, this.y = t.y - e.y, this.z = t.z - e.z, this
		},
		multiply: function(t, e) {
			return void 0 !== e ? this.multiplyVectors(t, e) : (this.x *= t.x, this.y *= t.y, this.z *= t.z, this)
		},
		multiplyScalar: function(t) {
			return this.x *= t, this.y *= t, this.z *= t, this
		},
		multiplyVectors: function(t, e) {
			return this.x = t.x * e.x, this.y = t.y * e.y, this.z = t.z * e.z, this
		},
		applyEuler: function() {
			var t = new r;
			return function(e) {
				return !e || e.isEuler, this.applyQuaternion(t.setFromEuler(e))
			}
		}(),
		applyAxisAngle: function() {
			var t = new r;
			return function(e, n) {
				return this.applyQuaternion(t.setFromAxisAngle(e, n))
			}
		}(),
		applyMatrix3: function(t) {
			var e = this.x,
				n = this.y,
				i = this.z,
				r = t.elements;
			return this.x = r[0] * e + r[3] * n + r[6] * i, this.y = r[1] * e + r[4] * n + r[7] * i, this.z = r[2] * e + r[5] * n + r[8] * i, this
		},
		applyMatrix4: function(t) {
			var e = this.x,
				n = this.y,
				i = this.z,
				r = t.elements,
				a = 1 / (r[3] * e + r[7] * n + r[11] * i + r[15]);
			return this.x = (r[0] * e + r[4] * n + r[8] * i + r[12]) * a, this.y = (r[1] * e + r[5] * n + r[9] * i + r[13]) * a, this.z = (r[2] * e + r[6] * n + r[10] * i + r[14]) * a, this
		},
		applyQuaternion: function(t) {
			var e = this.x,
				n = this.y,
				i = this.z,
				r = t.x,
				a = t.y,
				o = t.z,
				s = t.w,
				l = s * e + a * i - o * n,
				c = s * n + o * e - r * i,
				h = s * i + r * n - a * e,
				u = -r * e - a * n - o * i;
			return this.x = l * s + u * -r + c * -o - h * -a, this.y = c * s + u * -a + h * -r - l * -o, this.z = h * s + u * -o + l * -a - c * -r, this
		},
		project: function() {
			var t = new i;
			return function(e) {
				return t.multiplyMatrices(e.projectionMatrix, t.getInverse(e.matrixWorld)), this.applyMatrix4(t)
			}
		}(),
		unproject: function() {
			var t = new i;
			return function(e) {
				return t.multiplyMatrices(e.matrixWorld, t.getInverse(e.projectionMatrix)), this.applyMatrix4(t)
			}
		}(),
		transformDirection: function(t) {
			var e = this.x,
				n = this.y,
				i = this.z,
				r = t.elements;
			return this.x = r[0] * e + r[4] * n + r[8] * i, this.y = r[1] * e + r[5] * n + r[9] * i, this.z = r[2] * e + r[6] * n + r[10] * i, this.normalize()
		},
		divide: function(t) {
			return this.x /= t.x, this.y /= t.y, this.z /= t.z, this
		},
		divideScalar: function(t) {
			return this.multiplyScalar(1 / t)
		},
		min: function(t) {
			return this.x = Math.min(this.x, t.x), this.y = Math.min(this.y, t.y), this.z = Math.min(this.z, t.z), this
		},
		max: function(t) {
			return this.x = Math.max(this.x, t.x), this.y = Math.max(this.y, t.y), this.z = Math.max(this.z, t.z), this
		},
		clamp: function(t, e) {
			return this.x = Math.max(t.x, Math.min(e.x, this.x)), this.y = Math.max(t.y, Math.min(e.y, this.y)), this.z = Math.max(t.z, Math.min(e.z, this.z)), this
		},
		clampScalar: function() {
			var t = new a,
				e = new a;
			return function(n, i) {
				return t.set(n, n, n), e.set(i, i, i), this.clamp(t, e)
			}
		}(),
		clampLength: function(t, e) {
			var n = this.length();
			return this.divideScalar(n || 1).multiplyScalar(Math.max(t, Math.min(e, n)))
		},
		floor: function() {
			return this.x = Math.floor(this.x), this.y = Math.floor(this.y), this.z = Math.floor(this.z), this
		},
		ceil: function() {
			return this.x = Math.ceil(this.x), this.y = Math.ceil(this.y), this.z = Math.ceil(this.z), this
		},
		round: function() {
			return this.x = Math.round(this.x), this.y = Math.round(this.y), this.z = Math.round(this.z), this
		},
		roundToZero: function() {
			return this.x = this.x < 0 ? Math.ceil(this.x) : Math.floor(this.x), this.y = this.y < 0 ? Math.ceil(this.y) : Math.floor(this.y), this.z = this.z < 0 ? Math.ceil(this.z) : Math.floor(this.z), this
		},
		negate: function() {
			return this.x = -this.x, this.y = -this.y, this.z = -this.z, this
		},
		dot: function(t) {
			return this.x * t.x + this.y * t.y + this.z * t.z
		},
		lengthSq: function() {
			return this.x * this.x + this.y * this.y + this.z * this.z
		},
		length: function() {
			return Math.sqrt(this.x * this.x + this.y * this.y + this.z * this.z)
		},
		manhattanLength: function() {
			return Math.abs(this.x) + Math.abs(this.y) + Math.abs(this.z)
		},
		normalize: function() {
			return this.divideScalar(this.length() || 1)
		},
		setLength: function(t) {
			return this.normalize().multiplyScalar(t)
		},
		lerp: function(t, e) {
			return this.x += (t.x - this.x) * e, this.y += (t.y - this.y) * e, this.z += (t.z - this.z) * e, this
		},
		lerpVectors: function(t, e, n) {
			return this.subVectors(e, t).multiplyScalar(n).add(t)
		},
		cross: function(t, e) {
			return void 0 !== e ? this.crossVectors(t, e) : this.crossVectors(this, t)
		},
		crossVectors: function(t, e) {
			var n = t.x,
				i = t.y,
				r = t.z,
				a = e.x,
				o = e.y,
				s = e.z;
			return this.x = i * s - r * o, this.y = r * a - n * s, this.z = n * o - i * a, this
		},
		projectOnVector: function(t) {
			var e = t.dot(this) / t.lengthSq();
			return this.copy(t).multiplyScalar(e)
		},
		projectOnPlane: function() {
			var t = new a;
			return function(e) {
				return t.copy(this).projectOnVector(e), this.sub(t)
			}
		}(),
		reflect: function() {
			var t = new a;
			return function(e) {
				return this.sub(t.copy(e).multiplyScalar(2 * this.dot(e)))
			}
		}(),
		angleTo: function(t) {
			var e = this.dot(t) / Math.sqrt(this.lengthSq() * t.lengthSq());
			return Math.acos(Oa.clamp(e, -1, 1))
		},
		distanceTo: function(t) {
			return Math.sqrt(this.distanceToSquared(t))
		},
		distanceToSquared: function(t) {
			var e = this.x - t.x,
				n = this.y - t.y,
				i = this.z - t.z;
			return e * e + n * n + i * i
		},
		manhattanDistanceTo: function(t) {
			return Math.abs(this.x - t.x) + Math.abs(this.y - t.y) + Math.abs(this.z - t.z)
		},
		setFromSpherical: function(t) {
			var e = Math.sin(t.phi) * t.radius;
			return this.x = e * Math.sin(t.theta), this.y = Math.cos(t.phi) * t.radius, this.z = e * Math.cos(t.theta), this
		},
		setFromCylindrical: function(t) {
			return this.x = t.radius * Math.sin(t.theta), this.y = t.y, this.z = t.radius * Math.cos(t.theta), this
		},
		setFromMatrixPosition: function(t) {
			var e = t.elements;
			return this.x = e[12], this.y = e[13], this.z = e[14], this
		},
		setFromMatrixScale: function(t) {
			var e = this.setFromMatrixColumn(t, 0).length(),
				n = this.setFromMatrixColumn(t, 1).length(),
				i = this.setFromMatrixColumn(t, 2).length();
			return this.x = e, this.y = n, this.z = i, this
		},
		setFromMatrixColumn: function(t, e) {
			return this.fromArray(t.elements, 4 * e)
		},
		equals: function(t) {
			return t.x === this.x && t.y === this.y && t.z === this.z
		},
		fromArray: function(t, e) {
			return void 0 === e && (e = 0), this.x = t[e], this.y = t[e + 1], this.z = t[e + 2], this
		},
		toArray: function(t, e) {
			return void 0 === t && (t = []), void 0 === e && (e = 0), t[e] = this.x, t[e + 1] = this.y, t[e + 2] = this.z, t
		},
		fromBufferAttribute: function(t, e, n) {
			return this.x = t.getX(e), this.y = t.getY(e), this.z = t.getZ(e), this
		}
	}), Object.assign(o.prototype, {
		isMatrix3: !0,
		set: function(t, e, n, i, r, a, o, s, l) {
			var c = this.elements;
			return c[0] = t, c[1] = i, c[2] = o, c[3] = e, c[4] = r, c[5] = s, c[6] = n, c[7] = a, c[8] = l, this
		},
		identity: function() {
			return this.set(1, 0, 0, 0, 1, 0, 0, 0, 1), this
		},
		clone: function() {
			return(new this.constructor).fromArray(this.elements)
		},
		copy: function(t) {
			var e = this.elements,
				n = t.elements;
			return e[0] = n[0], e[1] = n[1], e[2] = n[2], e[3] = n[3], e[4] = n[4], e[5] = n[5], e[6] = n[6], e[7] = n[7], e[8] = n[8], this
		},
		setFromMatrix4: function(t) {
			var e = t.elements;
			return this.set(e[0], e[4], e[8], e[1], e[5], e[9], e[2], e[6], e[10]), this
		},
		applyToBufferAttribute: function() {
			var t = new a;
			return function(e) {
				for(var n = 0, i = e.count; n < i; n++) t.x = e.getX(n), t.y = e.getY(n), t.z = e.getZ(n), t.applyMatrix3(this), e.setXYZ(n, t.x, t.y, t.z);
				return e
			}
		}(),
		multiply: function(t) {
			return this.multiplyMatrices(this, t)
		},
		premultiply: function(t) {
			return this.multiplyMatrices(t, this)
		},
		multiplyMatrices: function(t, e) {
			var n = t.elements,
				i = e.elements,
				r = this.elements,
				a = n[0],
				o = n[3],
				s = n[6],
				l = n[1],
				c = n[4],
				h = n[7],
				u = n[2],
				f = n[5],
				p = n[8],
				d = i[0],
				m = i[3],
				g = i[6],
				v = i[1],
				_ = i[4],
				y = i[7],
				x = i[2],
				b = i[5],
				w = i[8];
			return r[0] = a * d + o * v + s * x, r[3] = a * m + o * _ + s * b, r[6] = a * g + o * y + s * w, r[1] = l * d + c * v + h * x, r[4] = l * m + c * _ + h * b, r[7] = l * g + c * y + h * w, r[2] = u * d + f * v + p * x, r[5] = u * m + f * _ + p * b, r[8] = u * g + f * y + p * w, this
		},
		multiplyScalar: function(t) {
			var e = this.elements;
			return e[0] *= t, e[3] *= t, e[6] *= t, e[1] *= t, e[4] *= t, e[7] *= t, e[2] *= t, e[5] *= t, e[8] *= t, this
		},
		determinant: function() {
			var t = this.elements,
				e = t[0],
				n = t[1],
				i = t[2],
				r = t[3],
				a = t[4],
				o = t[5],
				s = t[6],
				l = t[7],
				c = t[8];
			return e * a * c - e * o * l - n * r * c + n * o * s + i * r * l - i * a * s
		},
		getInverse: function(t, e) {
			t && t.isMatrix4;
			var n = t.elements,
				i = this.elements,
				r = n[0],
				a = n[1],
				o = n[2],
				s = n[3],
				l = n[4],
				c = n[5],
				h = n[6],
				u = n[7],
				f = n[8],
				p = f * l - c * u,
				d = c * h - f * s,
				m = u * s - l * h,
				g = r * p + a * d + o * m;
			if(0 === g) return this.identity();
			var v = 1 / g;
			return i[0] = p * v, i[1] = (o * u - f * a) * v, i[2] = (c * a - o * l) * v, i[3] = d * v, i[4] = (f * r - o * h) * v, i[5] = (o * s - c * r) * v, i[6] = m * v, i[7] = (a * h - u * r) * v, i[8] = (l * r - a * s) * v, this
		},
		transpose: function() {
			var t, e = this.elements;
			return t = e[1], e[1] = e[3], e[3] = t, t = e[2], e[2] = e[6], e[6] = t, t = e[5], e[5] = e[7], e[7] = t, this
		},
		getNormalMatrix: function(t) {
			return this.setFromMatrix4(t).getInverse(this).transpose()
		},
		transposeIntoArray: function(t) {
			var e = this.elements;
			return t[0] = e[0], t[1] = e[3], t[2] = e[6], t[3] = e[1], t[4] = e[4], t[5] = e[7], t[6] = e[2], t[7] = e[5], t[8] = e[8], this
		},
		setUvTransform: function(t, e, n, i, r, a, o) {
			var s = Math.cos(r),
				l = Math.sin(r);
			this.set(n * s, n * l, -n * (s * a + l * o) + a + t, -i * l, i * s, -i * (-l * a + s * o) + o + e, 0, 0, 1)
		},
		scale: function(t, e) {
			var n = this.elements;
			return n[0] *= t, n[3] *= t, n[6] *= t, n[1] *= e, n[4] *= e, n[7] *= e, this
		},
		rotate: function(t) {
			var e = Math.cos(t),
				n = Math.sin(t),
				i = this.elements,
				r = i[0],
				a = i[3],
				o = i[6],
				s = i[1],
				l = i[4],
				c = i[7];
			return i[0] = e * r + n * s, i[3] = e * a + n * l, i[6] = e * o + n * c, i[1] = -n * r + e * s, i[4] = -n * a + e * l, i[7] = -n * o + e * c, this
		},
		translate: function(t, e) {
			var n = this.elements;
			return n[0] += t * n[2], n[3] += t * n[5], n[6] += t * n[8], n[1] += e * n[2], n[4] += e * n[5], n[7] += e * n[8], this
		},
		equals: function(t) {
			for(var e = this.elements, n = t.elements, i = 0; i < 9; i++)
				if(e[i] !== n[i]) return !1;
			return !0
		},
		fromArray: function(t, e) {
			void 0 === e && (e = 0);
			for(var n = 0; n < 9; n++) this.elements[n] = t[n + e];
			return this
		},
		toArray: function(t, e) {
			void 0 === t && (t = []), void 0 === e && (e = 0);
			var n = this.elements;
			return t[e] = n[0], t[e + 1] = n[1], t[e + 2] = n[2], t[e + 3] = n[3], t[e + 4] = n[4], t[e + 5] = n[5], t[e + 6] = n[6], t[e + 7] = n[7], t[e + 8] = n[8], t
		}
	});
	var Na = 0;
	s.DEFAULT_IMAGE = void 0, s.DEFAULT_MAPPING = 300, Object.defineProperty(s.prototype, "needsUpdate", {
		set: function(t) {
			!0 === t && this.version++
		}
	}), Object.assign(s.prototype, e.prototype, {
		constructor: s,
		isTexture: !0,
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.name = t.name, this.image = t.image, this.mipmaps = t.mipmaps.slice(0), this.mapping = t.mapping, this.wrapS = t.wrapS, this.wrapT = t.wrapT, this.magFilter = t.magFilter, this.minFilter = t.minFilter, this.anisotropy = t.anisotropy, this.format = t.format, this.type = t.type, this.offset.copy(t.offset), this.repeat.copy(t.repeat), this.center.copy(t.center), this.rotation = t.rotation, this.matrixAutoUpdate = t.matrixAutoUpdate, this.matrix.copy(t.matrix), this.generateMipmaps = t.generateMipmaps, this.premultiplyAlpha = t.premultiplyAlpha, this.flipY = t.flipY, this.unpackAlignment = t.unpackAlignment, this.encoding = t.encoding, this
		},
		toJSON: function(t) {
			var e = void 0 === t || "string" == typeof t;
			if(!e && void 0 !== t.textures[this.uuid]) return t.textures[this.uuid];
			var n = {
				metadata: {
					version: 4.5,
					type: "Texture",
					generator: "Texture.toJSON"
				},
				uuid: this.uuid,
				name: this.name,
				mapping: this.mapping,
				repeat: [this.repeat.x, this.repeat.y],
				offset: [this.offset.x, this.offset.y],
				center: [this.center.x, this.center.y],
				rotation: this.rotation,
				wrap: [this.wrapS, this.wrapT],
				minFilter: this.minFilter,
				magFilter: this.magFilter,
				anisotropy: this.anisotropy,
				flipY: this.flipY
			};
			if(void 0 !== this.image) {
				var i = this.image;
				void 0 === i.uuid && (i.uuid = Oa.generateUUID()), e || void 0 !== t.images[i.uuid] || (t.images[i.uuid] = {
					uuid: i.uuid,
					url: function(t) {
						var e;
						if(t instanceof HTMLCanvasElement) e = t;
						else {
							(e = document.createElementNS("http://www.w3.org/1999/xhtml", "canvas")).width = t.width, e.height = t.height;
							var n = e.getContext("2d");
							t instanceof ImageData ? n.putImageData(t, 0, 0) : n.drawImage(t, 0, 0, t.width, t.height)
						}
						return e.width > 2048 || e.height > 2048 ? e.toDataURL("image/jpeg", .6) : e.toDataURL("image/png")
					}(i)
				}), n.image = i.uuid
			}
			return e || (t.textures[this.uuid] = n), n
		},
		dispose: function() {
			this.dispatchEvent({
				type: "dispose"
			})
		},
		transformUv: function(t) {
			if(300 === this.mapping) {
				if(t.applyMatrix3(this.matrix), t.x < 0 || t.x > 1) switch(this.wrapS) {
					case Ur:
						t.x = t.x - Math.floor(t.x);
						break;
					case Fr:
						t.x = t.x < 0 ? 0 : 1;
						break;
					case kr:
						1 === Math.abs(Math.floor(t.x) % 2) ? t.x = Math.ceil(t.x) - t.x : t.x = t.x - Math.floor(t.x)
				}
				if(t.y < 0 || t.y > 1) switch(this.wrapT) {
					case Ur:
						t.y = t.y - Math.floor(t.y);
						break;
					case Fr:
						t.y = t.y < 0 ? 0 : 1;
						break;
					case kr:
						1 === Math.abs(Math.floor(t.y) % 2) ? t.y = Math.ceil(t.y) - t.y : t.y = t.y - Math.floor(t.y)
				}
				this.flipY && (t.y = 1 - t.y)
			}
		}
	}), Object.assign(l.prototype, {
		isVector4: !0,
		set: function(t, e, n, i) {
			return this.x = t, this.y = e, this.z = n, this.w = i, this
		},
		setScalar: function(t) {
			return this.x = t, this.y = t, this.z = t, this.w = t, this
		},
		setX: function(t) {
			return this.x = t, this
		},
		setY: function(t) {
			return this.y = t, this
		},
		setZ: function(t) {
			return this.z = t, this
		},
		setW: function(t) {
			return this.w = t, this
		},
		setComponent: function(t, e) {
			switch(t) {
				case 0:
					this.x = e;
					break;
				case 1:
					this.y = e;
					break;
				case 2:
					this.z = e;
					break;
				case 3:
					this.w = e
			}
			return this
		},
		getComponent: function(t) {
			switch(t) {
				case 0:
					return this.x;
				case 1:
					return this.y;
				case 2:
					return this.z;
				case 3:
					return this.w
			}
		},
		clone: function() {
			return new this.constructor(this.x, this.y, this.z, this.w)
		},
		copy: function(t) {
			return this.x = t.x, this.y = t.y, this.z = t.z, this.w = void 0 !== t.w ? t.w : 1, this
		},
		add: function(t, e) {
			return void 0 !== e ? this.addVectors(t, e) : (this.x += t.x, this.y += t.y, this.z += t.z, this.w += t.w, this)
		},
		addScalar: function(t) {
			return this.x += t, this.y += t, this.z += t, this.w += t, this
		},
		addVectors: function(t, e) {
			return this.x = t.x + e.x, this.y = t.y + e.y, this.z = t.z + e.z, this.w = t.w + e.w, this
		},
		addScaledVector: function(t, e) {
			return this.x += t.x * e, this.y += t.y * e, this.z += t.z * e, this.w += t.w * e, this
		},
		sub: function(t, e) {
			return void 0 !== e ? this.subVectors(t, e) : (this.x -= t.x, this.y -= t.y, this.z -= t.z, this.w -= t.w, this)
		},
		subScalar: function(t) {
			return this.x -= t, this.y -= t, this.z -= t, this.w -= t, this
		},
		subVectors: function(t, e) {
			return this.x = t.x - e.x, this.y = t.y - e.y, this.z = t.z - e.z, this.w = t.w - e.w, this
		},
		multiplyScalar: function(t) {
			return this.x *= t, this.y *= t, this.z *= t, this.w *= t, this
		},
		applyMatrix4: function(t) {
			var e = this.x,
				n = this.y,
				i = this.z,
				r = this.w,
				a = t.elements;
			return this.x = a[0] * e + a[4] * n + a[8] * i + a[12] * r, this.y = a[1] * e + a[5] * n + a[9] * i + a[13] * r, this.z = a[2] * e + a[6] * n + a[10] * i + a[14] * r, this.w = a[3] * e + a[7] * n + a[11] * i + a[15] * r, this
		},
		divideScalar: function(t) {
			return this.multiplyScalar(1 / t)
		},
		setAxisAngleFromQuaternion: function(t) {
			this.w = 2 * Math.acos(t.w);
			var e = Math.sqrt(1 - t.w * t.w);
			return e < 1e-4 ? (this.x = 1, this.y = 0, this.z = 0) : (this.x = t.x / e, this.y = t.y / e, this.z = t.z / e), this
		},
		setAxisAngleFromRotationMatrix: function(t) {
			var e, n, i, r, a = t.elements,
				o = a[0],
				s = a[4],
				l = a[8],
				c = a[1],
				h = a[5],
				u = a[9],
				f = a[2],
				p = a[6],
				d = a[10];
			if(Math.abs(s - c) < .01 && Math.abs(l - f) < .01 && Math.abs(u - p) < .01) {
				if(Math.abs(s + c) < .1 && Math.abs(l + f) < .1 && Math.abs(u + p) < .1 && Math.abs(o + h + d - 3) < .1) return this.set(1, 0, 0, 0), this;
				e = Math.PI;
				var m = (o + 1) / 2,
					g = (h + 1) / 2,
					v = (d + 1) / 2,
					_ = (s + c) / 4,
					y = (l + f) / 4,
					x = (u + p) / 4;
				return m > g && m > v ? m < .01 ? (n = 0, i = .707106781, r = .707106781) : (i = _ / (n = Math.sqrt(m)), r = y / n) : g > v ? g < .01 ? (n = .707106781, i = 0, r = .707106781) : (n = _ / (i = Math.sqrt(g)), r = x / i) : v < .01 ? (n = .707106781, i = .707106781, r = 0) : (n = y / (r = Math.sqrt(v)), i = x / r), this.set(n, i, r, e), this
			}
			var b = Math.sqrt((p - u) * (p - u) + (l - f) * (l - f) + (c - s) * (c - s));
			return Math.abs(b) < .001 && (b = 1), this.x = (p - u) / b, this.y = (l - f) / b, this.z = (c - s) / b, this.w = Math.acos((o + h + d - 1) / 2), this
		},
		min: function(t) {
			return this.x = Math.min(this.x, t.x), this.y = Math.min(this.y, t.y), this.z = Math.min(this.z, t.z), this.w = Math.min(this.w, t.w), this
		},
		max: function(t) {
			return this.x = Math.max(this.x, t.x), this.y = Math.max(this.y, t.y), this.z = Math.max(this.z, t.z), this.w = Math.max(this.w, t.w), this
		},
		clamp: function(t, e) {
			return this.x = Math.max(t.x, Math.min(e.x, this.x)), this.y = Math.max(t.y, Math.min(e.y, this.y)), this.z = Math.max(t.z, Math.min(e.z, this.z)), this.w = Math.max(t.w, Math.min(e.w, this.w)), this
		},
		clampScalar: function() {
			var t, e;
			return function(n, i) {
				return void 0 === t && (t = new l, e = new l), t.set(n, n, n, n), e.set(i, i, i, i), this.clamp(t, e)
			}
		}(),
		clampLength: function(t, e) {
			var n = this.length();
			return this.divideScalar(n || 1).multiplyScalar(Math.max(t, Math.min(e, n)))
		},
		floor: function() {
			return this.x = Math.floor(this.x), this.y = Math.floor(this.y), this.z = Math.floor(this.z), this.w = Math.floor(this.w), this
		},
		ceil: function() {
			return this.x = Math.ceil(this.x), this.y = Math.ceil(this.y), this.z = Math.ceil(this.z), this.w = Math.ceil(this.w), this
		},
		round: function() {
			return this.x = Math.round(this.x), this.y = Math.round(this.y), this.z = Math.round(this.z), this.w = Math.round(this.w), this
		},
		roundToZero: function() {
			return this.x = this.x < 0 ? Math.ceil(this.x) : Math.floor(this.x), this.y = this.y < 0 ? Math.ceil(this.y) : Math.floor(this.y), this.z = this.z < 0 ? Math.ceil(this.z) : Math.floor(this.z), this.w = this.w < 0 ? Math.ceil(this.w) : Math.floor(this.w), this
		},
		negate: function() {
			return this.x = -this.x, this.y = -this.y, this.z = -this.z, this.w = -this.w, this
		},
		dot: function(t) {
			return this.x * t.x + this.y * t.y + this.z * t.z + this.w * t.w
		},
		lengthSq: function() {
			return this.x * this.x + this.y * this.y + this.z * this.z + this.w * this.w
		},
		length: function() {
			return Math.sqrt(this.x * this.x + this.y * this.y + this.z * this.z + this.w * this.w)
		},
		manhattanLength: function() {
			return Math.abs(this.x) + Math.abs(this.y) + Math.abs(this.z) + Math.abs(this.w)
		},
		normalize: function() {
			return this.divideScalar(this.length() || 1)
		},
		setLength: function(t) {
			return this.normalize().multiplyScalar(t)
		},
		lerp: function(t, e) {
			return this.x += (t.x - this.x) * e, this.y += (t.y - this.y) * e, this.z += (t.z - this.z) * e, this.w += (t.w - this.w) * e, this
		},
		lerpVectors: function(t, e, n) {
			return this.subVectors(e, t).multiplyScalar(n).add(t)
		},
		equals: function(t) {
			return t.x === this.x && t.y === this.y && t.z === this.z && t.w === this.w
		},
		fromArray: function(t, e) {
			return void 0 === e && (e = 0), this.x = t[e], this.y = t[e + 1], this.z = t[e + 2], this.w = t[e + 3], this
		},
		toArray: function(t, e) {
			return void 0 === t && (t = []), void 0 === e && (e = 0), t[e] = this.x, t[e + 1] = this.y, t[e + 2] = this.z, t[e + 3] = this.w, t
		},
		fromBufferAttribute: function(t, e, n) {
			return this.x = t.getX(e), this.y = t.getY(e), this.z = t.getZ(e), this.w = t.getW(e), this
		}
	}), Object.assign(c.prototype, e.prototype, {
		isWt: !0,
		setSize: function(t, e) {
			this.width === t && this.height === e || (this.width = t, this.height = e, this.dispose()), this.viewport.set(0, 0, t, e), this.scissor.set(0, 0, t, e)
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.width = t.width, this.height = t.height, this.viewport.copy(t.viewport), this.texture = t.texture.clone(), this.depthBuffer = t.depthBuffer, this.stencilBuffer = t.stencilBuffer, this.depthTexture = t.depthTexture, this
		},
		dispose: function() {
			this.dispatchEvent({
				type: "dispose"
			})
		}
	}), (h.prototype = Object.create(c.prototype)).constructor = h, h.prototype.isWtCube = !0, u.prototype = Object.create(s.prototype), u.prototype.constructor = u, u.prototype.isDataTexture = !0, (f.prototype = Object.create(s.prototype)).constructor = f, f.prototype.isCubeTexture = !0, Object.defineProperty(f.prototype, "images", {
		get: function() {
			return this.image
		},
		set: function(t) {
			this.image = t
		}
	});
	var Da = new s,
		za = new f,
		Ua = [],
		Fa = [],
		ka = new Float32Array(16),
		Ba = new Float32Array(9);
	j.prototype.setValue = function(t, e) {
		for(var n = this.seq, i = 0, r = n.length; i !== r; ++i) {
			var a = n[i];
			a.setValue(t, e[a.id])
		}
	};
	var Va = /([\w\d_]+)(\])?(\[|\.)?/g;
	X.prototype.setValue = function(t, e, n) {
		var i = this.map[e];
		void 0 !== i && i.setValue(t, n, this.renderer)
	}, X.prototype.setOptional = function(t, e, n) {
		var i = e[n];
		void 0 !== i && this.setValue(t, n, i)
	}, X.upload = function(t, e, n, i) {
		for(var r = 0, a = e.length; r !== a; ++r) {
			var o = e[r],
				s = n[o.id];
			!1 !== s.needsUpdate && o.setValue(t, s.value, i)
		}
	}, X.seqWithValue = function(t, e) {
		for(var n = [], i = 0, r = t.length; i !== r; ++i) {
			var a = t[i];
			a.id in e && n.push(a)
		}
		return n
	};
	var ja = {
		aliceblue: 15792383,
		antiquewhite: 16444375,
		aqua: 65535,
		aquamarine: 8388564,
		azure: 15794175,
		beige: 16119260,
		bisque: 16770244,
		black: 0,
		blanchedalmond: 16772045,
		blue: 255,
		blueviolet: 9055202,
		brown: 10824234,
		burlywood: 14596231,
		cadetblue: 6266528,
		chartreuse: 8388352,
		chocolate: 13789470,
		coral: 16744272,
		cornflowerblue: 6591981,
		cornsilk: 16775388,
		crimson: 14423100,
		cyan: 65535,
		darkblue: 139,
		darkcyan: 35723,
		darkgoldenrod: 12092939,
		darkgray: 11119017,
		darkgreen: 25600,
		darkgrey: 11119017,
		darkkhaki: 12433259,
		darkmagenta: 9109643,
		darkolivegreen: 5597999,
		darkorange: 16747520,
		darkorchid: 10040012,
		darkred: 9109504,
		darksalmon: 15308410,
		darkseagreen: 9419919,
		darkslateblue: 4734347,
		darkslategray: 3100495,
		darkslategrey: 3100495,
		darkturquoise: 52945,
		darkviolet: 9699539,
		deeppink: 16716947,
		deepskyblue: 49151,
		dimgray: 6908265,
		dimgrey: 6908265,
		dodgerblue: 2003199,
		firebrick: 11674146,
		floralwhite: 16775920,
		forestgreen: 2263842,
		fuchsia: 16711935,
		gainsboro: 14474460,
		ghostwhite: 16316671,
		gold: 16766720,
		goldenrod: 14329120,
		gray: 8421504,
		green: 32768,
		greenyellow: 11403055,
		grey: 8421504,
		honeydew: 15794160,
		hotpink: 16738740,
		indianred: 13458524,
		indigo: 4915330,
		ivory: 16777200,
		khaki: 15787660,
		lavender: 15132410,
		lavenderblush: 16773365,
		lawngreen: 8190976,
		lemonchiffon: 16775885,
		lightblue: 11393254,
		lightcoral: 15761536,
		lightcyan: 14745599,
		lightgoldenrodyellow: 16448210,
		lightgray: 13882323,
		lightgreen: 9498256,
		lightgrey: 13882323,
		lightpink: 16758465,
		lightsalmon: 16752762,
		lightseagreen: 2142890,
		lightskyblue: 8900346,
		lightslategray: 7833753,
		lightslategrey: 7833753,
		lightsteelblue: 11584734,
		lightyellow: 16777184,
		lime: 65280,
		limegreen: 3329330,
		linen: 16445670,
		magenta: 16711935,
		maroon: 8388608,
		mediumaquamarine: 6737322,
		mediumblue: 205,
		mediumorchid: 12211667,
		mediumpurple: 9662683,
		mediumseagreen: 3978097,
		mediumslateblue: 8087790,
		mediumspringgreen: 64154,
		mediumturquoise: 4772300,
		mediumvioletred: 13047173,
		midnightblue: 1644912,
		mintcream: 16121850,
		mistyrose: 16770273,
		moccasin: 16770229,
		navajowhite: 16768685,
		navy: 128,
		oldlace: 16643558,
		olive: 8421376,
		olivedrab: 7048739,
		orange: 16753920,
		orangered: 16729344,
		orchid: 14315734,
		palegoldenrod: 15657130,
		palegreen: 10025880,
		paleturquoise: 11529966,
		palevioletred: 14381203,
		papayawhip: 16773077,
		peachpuff: 16767673,
		peru: 13468991,
		pink: 16761035,
		plum: 14524637,
		powderblue: 11591910,
		purple: 8388736,
		rebeccapurple: 6697881,
		red: 16711680,
		rosybrown: 12357519,
		royalblue: 4286945,
		saddlebrown: 9127187,
		salmon: 16416882,
		sandybrown: 16032864,
		seagreen: 3050327,
		seashell: 16774638,
		sienna: 10506797,
		silver: 12632256,
		skyblue: 8900331,
		slateblue: 6970061,
		slategray: 7372944,
		slategrey: 7372944,
		snow: 16775930,
		springgreen: 65407,
		steelblue: 4620980,
		tan: 13808780,
		teal: 32896,
		thistle: 14204888,
		tomato: 16737095,
		turquoise: 4251856,
		violet: 15631086,
		wheat: 16113331,
		white: 16777215,
		whitesmoke: 16119285,
		yellow: 16776960,
		yellowgreen: 10145074
	};
	Object.assign(Y.prototype, {
		isColor: !0,
		r: 1,
		g: 1,
		b: 1,
		set: function(t) {
			return t && t.isColor ? this.copy(t) : "number" == typeof t ? this.setHex(t) : "string" == typeof t && this.setStyle(t), this
		},
		setScalar: function(t) {
			return this.r = t, this.g = t, this.b = t, this
		},
		setHex: function(t) {
			return t = Math.floor(t), this.r = (t >> 16 & 255) / 255, this.g = (t >> 8 & 255) / 255, this.b = (255 & t) / 255, this
		},
		setRGB: function(t, e, n) {
			return this.r = t, this.g = e, this.b = n, this
		},
		setHSL: function() {
			function t(t, e, n) {
				return n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? t + 6 * (e - t) * n : n < .5 ? e : n < 2 / 3 ? t + 6 * (e - t) * (2 / 3 - n) : t
			}
			return function(e, n, i) {
				if(e = Oa.euclideanModulo(e, 1), n = Oa.clamp(n, 0, 1), i = Oa.clamp(i, 0, 1), 0 === n) this.r = this.g = this.b = i;
				else {
					var r = i <= .5 ? i * (1 + n) : i + n - i * n,
						a = 2 * i - r;
					this.r = t(a, r, e + 1 / 3), this.g = t(a, r, e), this.b = t(a, r, e - 1 / 3)
				}
				return this
			}
		}(),
		setStyle: function(t) {
			function e(t) {
				void 0 !== t && parseFloat(t)
			}
			var n;
			if(n = /^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(t)) {
				var i, r = n[1],
					a = n[2];
				switch(r) {
					case "rgb":
					case "rgba":
						if(i = /^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(a)) return this.r = Math.min(255, parseInt(i[1], 10)) / 255, this.g = Math.min(255, parseInt(i[2], 10)) / 255, this.b = Math.min(255, parseInt(i[3], 10)) / 255, e(i[5]), this;
						if(i = /^(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(a)) return this.r = Math.min(100, parseInt(i[1], 10)) / 100, this.g = Math.min(100, parseInt(i[2], 10)) / 100, this.b = Math.min(100, parseInt(i[3], 10)) / 100, e(i[5]), this;
						break;
					case "hsl":
					case "hsla":
						if(i = /^([0-9]*\.?[0-9]+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(a)) {
							var o = parseFloat(i[1]) / 360,
								s = parseInt(i[2], 10) / 100,
								l = parseInt(i[3], 10) / 100;
							return e(i[5]), this.setHSL(o, s, l)
						}
				}
			} else if(n = /^\#([A-Fa-f0-9]+)$/.exec(t)) {
				var c = (h = n[1]).length;
				if(3 === c) return this.r = parseInt(h.charAt(0) + h.charAt(0), 16) / 255, this.g = parseInt(h.charAt(1) + h.charAt(1), 16) / 255, this.b = parseInt(h.charAt(2) + h.charAt(2), 16) / 255, this;
				if(6 === c) return this.r = parseInt(h.charAt(0) + h.charAt(1), 16) / 255, this.g = parseInt(h.charAt(2) + h.charAt(3), 16) / 255, this.b = parseInt(h.charAt(4) + h.charAt(5), 16) / 255, this
			}
			if(t && t.length > 0) {
				var h = ja[t];
				void 0 !== h && this.setHex(h)
			}
			return this
		},
		clone: function() {
			return new this.constructor(this.r, this.g, this.b)
		},
		copy: function(t) {
			return this.r = t.r, this.g = t.g, this.b = t.b, this
		},
		copyGammaToLinear: function(t, e) {
			return void 0 === e && (e = 2), this.r = Math.pow(t.r, e), this.g = Math.pow(t.g, e), this.b = Math.pow(t.b, e), this
		},
		copyLinearToGamma: function(t, e) {
			void 0 === e && (e = 2);
			var n = e > 0 ? 1 / e : 1;
			return this.r = Math.pow(t.r, n), this.g = Math.pow(t.g, n), this.b = Math.pow(t.b, n), this
		},
		convertGammaToLinear: function() {
			var t = this.r,
				e = this.g,
				n = this.b;
			return this.r = t * t, this.g = e * e, this.b = n * n, this
		},
		convertLinearToGamma: function() {
			return this.r = Math.sqrt(this.r), this.g = Math.sqrt(this.g), this.b = Math.sqrt(this.b), this
		},
		getHex: function() {
			return 255 * this.r << 16 ^ 255 * this.g << 8 ^ 255 * this.b << 0
		},
		getHexString: function() {
			return("000000" + this.getHex().toString(16)).slice(-6)
		},
		getHSL: function(t) {
			var e, n, i = t || {
					h: 0,
					s: 0,
					l: 0
				},
				r = this.r,
				a = this.g,
				o = this.b,
				s = Math.max(r, a, o),
				l = Math.min(r, a, o),
				c = (l + s) / 2;
			if(l === s) e = 0, n = 0;
			else {
				var h = s - l;
				switch(n = c <= .5 ? h / (s + l) : h / (2 - s - l), s) {
					case r:
						e = (a - o) / h + (a < o ? 6 : 0);
						break;
					case a:
						e = (o - r) / h + 2;
						break;
					case o:
						e = (r - a) / h + 4
				}
				e /= 6
			}
			return i.h = e, i.s = n, i.l = c, i
		},
		getStyle: function() {
			return "rgb(" + (255 * this.r | 0) + "," + (255 * this.g | 0) + "," + (255 * this.b | 0) + ")"
		},
		offsetHSL: function(t, e, n) {
			var i = this.getHSL();
			return i.h += t, i.s += e, i.l += n, this.setHSL(i.h, i.s, i.l), this
		},
		add: function(t) {
			return this.r += t.r, this.g += t.g, this.b += t.b, this
		},
		addColors: function(t, e) {
			return this.r = t.r + e.r, this.g = t.g + e.g, this.b = t.b + e.b, this
		},
		addScalar: function(t) {
			return this.r += t, this.g += t, this.b += t, this
		},
		sub: function(t) {
			return this.r = Math.max(0, this.r - t.r), this.g = Math.max(0, this.g - t.g), this.b = Math.max(0, this.b - t.b), this
		},
		multiply: function(t) {
			return this.r *= t.r, this.g *= t.g, this.b *= t.b, this
		},
		multiplyScalar: function(t) {
			return this.r *= t, this.g *= t, this.b *= t, this
		},
		lerp: function(t, e) {
			return this.r += (t.r - this.r) * e, this.g += (t.g - this.g) * e, this.b += (t.b - this.b) * e, this
		},
		equals: function(t) {
			return t.r === this.r && t.g === this.g && t.b === this.b
		},
		fromArray: function(t, e) {
			return void 0 === e && (e = 0), this.r = t[e], this.g = t[e + 1], this.b = t[e + 2], this
		},
		toArray: function(t, e) {
			return void 0 === t && (t = []), void 0 === e && (e = 0), t[e] = this.r, t[e + 1] = this.g, t[e + 2] = this.b, t
		},
		toJSON: function() {
			return this.getHex()
		}
	});
	var Ha = {
			common: {
				diffuse: {
					value: new Y(15658734)
				},
				opacity: {
					value: 1
				},
				map: {
					value: null
				},
				uvTransform: {
					value: new o
				},
				alphaMap: {
					value: null
				}
			},
			specularmap: {
				specularMap: {
					value: null
				}
			},
			envmap: {
				envMap: {
					value: null
				},
				flipEnvMap: {
					value: -1
				},
				reflectivity: {
					value: 1
				},
				refractionRatio: {
					value: .98
				}
			},
			aomap: {
				aoMap: {
					value: null
				},
				aoMapIntensity: {
					value: 1
				}
			},
			lightmap: {
				lightMap: {
					value: null
				},
				lightMapIntensity: {
					value: 1
				}
			},
			emissivemap: {
				emissiveMap: {
					value: null
				}
			},
			bumpmap: {
				bumpMap: {
					value: null
				},
				bumpScale: {
					value: 1
				}
			},
			normalmap: {
				normalMap: {
					value: null
				},
				normalScale: {
					value: new n(1, 1)
				}
			},
			displacementmap: {
				displacementMap: {
					value: null
				},
				displacementScale: {
					value: 1
				},
				displacementBias: {
					value: 0
				}
			},
			roughnessmap: {
				roughnessMap: {
					value: null
				}
			},
			metalnessmap: {
				metalnessMap: {
					value: null
				}
			},
			gradientmap: {
				gradientMap: {
					value: null
				}
			},
			fog: {
				fogDensity: {
					value: 25e-5
				},
				fogNear: {
					value: 1
				},
				fogFar: {
					value: 2e3
				},
				fogColor: {
					value: new Y(16777215)
				}
			},
			lights: {
				ambientLightColor: {
					value: []
				},
				directionalLights: {
					value: [],
					properties: {
						direction: {},
						color: {},
						shadow: {},
						shadowBias: {},
						shadowRadius: {},
						shadowMapSize: {}
					}
				},
				directionalShadowMap: {
					value: []
				},
				directionalShadowMatrix: {
					value: []
				},
				spotLights: {
					value: [],
					properties: {
						color: {},
						position: {},
						direction: {},
						distance: {},
						coneCos: {},
						penumbraCos: {},
						decay: {},
						shadow: {},
						shadowBias: {},
						shadowRadius: {},
						shadowMapSize: {}
					}
				},
				spotShadowMap: {
					value: []
				},
				spotShadowMatrix: {
					value: []
				},
				pointLights: {
					value: [],
					properties: {
						color: {},
						position: {},
						decay: {},
						distance: {},
						shadow: {},
						shadowBias: {},
						shadowRadius: {},
						shadowMapSize: {},
						shadowCameraNear: {},
						shadowCameraFar: {}
					}
				},
				pointShadowMap: {
					value: []
				},
				pointShadowMatrix: {
					value: []
				},
				hemisphereLights: {
					value: [],
					properties: {
						direction: {},
						skyColor: {},
						groundColor: {}
					}
				},
				rectAreaLights: {
					value: [],
					properties: {
						color: {},
						position: {},
						width: {},
						height: {}
					}
				}
			},
			points: {
				diffuse: {
					value: new Y(15658734)
				},
				opacity: {
					value: 1
				},
				size: {
					value: 1
				},
				scale: {
					value: 1
				},
				map: {
					value: null
				},
				uvTransform: {
					value: new o
				}
			}
		},
		Wa = {
			merge: function(t) {
				for(var e = {}, n = 0; n < t.length; n++) {
					var i = this.clone(t[n]);
					for(var r in i) e[r] = i[r]
				}
				return e
			},
			clone: function(t) {
				var e = {};
				for(var n in t) {
					e[n] = {};
					for(var i in t[n]) {
						var r = t[n][i];
						r && (r.isColor || r.isMatrix3 || r.isMatrix4 || r.isVector2 || r.isVector3 || r.isVector4 || r.isTexture) ? e[n][i] = r.clone() : Array.isArray(r) ? e[n][i] = r.slice() : e[n][i] = r
					}
				}
				return e
			}
		},
		Xa = {
			alphamap_fragment: "#ifdef USE_ALPHAMAP\n\tdiffuseColor.a *= texture2D( alphaMap, vUv ).g;\n#endif\n",
			alphamap_pars_fragment: "#ifdef USE_ALPHAMAP\n\tuniform sampler2D alphaMap;\n#endif\n",
			alphatest_fragment: "#ifdef ALPHATEST\n\tif ( diffuseColor.a < ALPHATEST ) discard;\n#endif\n",
			aomap_fragment: "#ifdef USE_AOMAP\n\tfloat ambientOcclusion = ( texture2D( aoMap, vUv2 ).r - 1.0 ) * aoMapIntensity + 1.0;\n\treflectedLight.indirectDiffuse *= ambientOcclusion;\n\t#if defined( USE_ENVMAP ) && defined( PHYSICAL )\n\t\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\t\treflectedLight.indirectSpecular *= computeSpecularOcclusion( dotNV, ambientOcclusion, material.specularRoughness );\n\t#endif\n#endif\n",
			aomap_pars_fragment: "#ifdef USE_AOMAP\n\tuniform sampler2D aoMap;\n\tuniform float aoMapIntensity;\n#endif",
			begin_vertex: "\nvec3 transformed = vec3( position );\n",
			beginnormal_vertex: "\nvec3 objectNormal = vec3( normal );\n",
			bsdfs: "float punctualLightIntensityToIrradianceFactor( const in float lightDistance, const in float cutoffDistance, const in float decayExponent ) {\n\tif( decayExponent > 0.0 ) {\n#if defined ( PHYSICALLY_CORRECT_LIGHTS )\n\t\tfloat distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );\n\t\tfloat maxDistanceCutoffFactor = pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\n\t\treturn distanceFalloff * maxDistanceCutoffFactor;\n#else\n\t\treturn pow( saturate( -lightDistance / cutoffDistance + 1.0 ), decayExponent );\n#endif\n\t}\n\treturn 1.0;\n}\nvec3 BRDF_Diffuse_Lambert( const in vec3 diffuseColor ) {\n\treturn RECIPROCAL_PI * diffuseColor;\n}\nvec3 F_Schlick( const in vec3 specularColor, const in float dotLH ) {\n\tfloat fresnel = exp2( ( -5.55473 * dotLH - 6.98316 ) * dotLH );\n\treturn ( 1.0 - specularColor ) * fresnel + specularColor;\n}\nfloat G_GGX_Smith( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gl = dotNL + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\tfloat gv = dotNV + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\treturn 1.0 / ( gl * gv );\n}\nfloat G_GGX_SmithCorrelated( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gv = dotNL * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\tfloat gl = dotNV * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\treturn 0.5 / max( gv + gl, EPSILON );\n}\nfloat D_GGX( const in float alpha, const in float dotNH ) {\n\tfloat a2 = pow2( alpha );\n\tfloat denom = pow2( dotNH ) * ( a2 - 1.0 ) + 1.0;\n\treturn RECIPROCAL_PI * a2 / pow2( denom );\n}\nvec3 BRDF_Specular_GGX( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float roughness ) {\n\tfloat alpha = pow2( roughness );\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNL = saturate( dot( geometry.normal, incidentLight.direction ) );\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_GGX_SmithCorrelated( alpha, dotNL, dotNV );\n\tfloat D = D_GGX( alpha, dotNH );\n\treturn F * ( G * D );\n}\nvec2 LTC_Uv( const in vec3 N, const in vec3 V, const in float roughness ) {\n\tconst float LUT_SIZE  = 64.0;\n\tconst float LUT_SCALE = ( LUT_SIZE - 1.0 ) / LUT_SIZE;\n\tconst float LUT_BIAS  = 0.5 / LUT_SIZE;\n\tfloat theta = acos( dot( N, V ) );\n\tvec2 uv = vec2(\n\t\tsqrt( saturate( roughness ) ),\n\t\tsaturate( theta / ( 0.5 * PI ) ) );\n\tuv = uv * LUT_SCALE + LUT_BIAS;\n\treturn uv;\n}\nfloat LTC_ClippedSphereFormFactor( const in vec3 f ) {\n\tfloat l = length( f );\n\treturn max( ( l * l + f.z ) / ( l + 1.0 ), 0.0 );\n}\nvec3 LTC_EdgeVectorFormFactor( const in vec3 v1, const in vec3 v2 ) {\n\tfloat x = dot( v1, v2 );\n\tfloat y = abs( x );\n\tfloat a = 0.86267 + (0.49788 + 0.01436 * y ) * y;\n\tfloat b = 3.45068 + (4.18814 + y) * y;\n\tfloat v = a / b;\n\tfloat theta_sintheta = (x > 0.0) ? v : 0.5 * inversesqrt( 1.0 - x * x ) - v;\n\treturn cross( v1, v2 ) * theta_sintheta;\n}\nvec3 LTC_Evaluate( const in vec3 N, const in vec3 V, const in vec3 P, const in mat3 mInv, const in vec3 rectCoords[ 4 ] ) {\n\tvec3 v1 = rectCoords[ 1 ] - rectCoords[ 0 ];\n\tvec3 v2 = rectCoords[ 3 ] - rectCoords[ 0 ];\n\tvec3 lightNormal = cross( v1, v2 );\n\tif( dot( lightNormal, P - rectCoords[ 0 ] ) < 0.0 ) return vec3( 0.0 );\n\tvec3 T1, T2;\n\tT1 = normalize( V - N * dot( V, N ) );\n\tT2 = - cross( N, T1 );\n\tmat3 mat = mInv * transposeMat3( mat3( T1, T2, N ) );\n\tvec3 coords[ 4 ];\n\tcoords[ 0 ] = mat * ( rectCoords[ 0 ] - P );\n\tcoords[ 1 ] = mat * ( rectCoords[ 1 ] - P );\n\tcoords[ 2 ] = mat * ( rectCoords[ 2 ] - P );\n\tcoords[ 3 ] = mat * ( rectCoords[ 3 ] - P );\n\tcoords[ 0 ] = normalize( coords[ 0 ] );\n\tcoords[ 1 ] = normalize( coords[ 1 ] );\n\tcoords[ 2 ] = normalize( coords[ 2 ] );\n\tcoords[ 3 ] = normalize( coords[ 3 ] );\n\tvec3 vectorFormFactor = vec3( 0.0 );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 0 ], coords[ 1 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 1 ], coords[ 2 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 2 ], coords[ 3 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 3 ], coords[ 0 ] );\n\tvec3 result = vec3( LTC_ClippedSphereFormFactor( vectorFormFactor ) );\n\treturn result;\n}\nvec3 BRDF_Specular_GGX_Environment( const in GeometricContext geometry, const in vec3 specularColor, const in float roughness ) {\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tconst vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );\n\tconst vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );\n\tvec4 r = roughness * c0 + c1;\n\tfloat a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;\n\tvec2 AB = vec2( -1.04, 1.04 ) * a004 + r.zw;\n\treturn specularColor * AB.x + AB.y;\n}\nfloat G_BlinnPhong_Implicit( ) {\n\treturn 0.25;\n}\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\n\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\n}\nvec3 BRDF_Specular_BlinnPhong( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float shininess ) {\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_BlinnPhong_Implicit( );\n\tfloat D = D_BlinnPhong( shininess, dotNH );\n\treturn F * ( G * D );\n}\nfloat GGXRoughnessToBlinnExponent( const in float ggxRoughness ) {\n\treturn ( 2.0 / pow2( ggxRoughness + 0.0001 ) - 2.0 );\n}\nfloat BlinnExponentToGGXRoughness( const in float blinnExponent ) {\n\treturn sqrt( 2.0 / ( blinnExponent + 2.0 ) );\n}\n",
			bumpmap_pars_fragment: "#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy ) {\n\t\tvec3 vSigmaX = vec3( dFdx( surf_pos.x ), dFdx( surf_pos.y ), dFdx( surf_pos.z ) );\n\t\tvec3 vSigmaY = vec3( dFdy( surf_pos.x ), dFdy( surf_pos.y ), dFdy( surf_pos.z ) );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 );\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif\n",
			clipping_planes_fragment: "#if NUM_CLIPPING_PLANES > 0\n\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; ++ i ) {\n\t\tvec4 plane = cs[ i ];\n\t\tif ( dot( vViewPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t\t\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; ++ i ) {\n\t\t\tvec4 plane = cs[ i ];\n\t\t\tclipped = ( dot( vViewPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\tif ( clipped ) discard;\n\t\n\t#endif\n#endif\n",
			clipping_planes_pars_fragment: "#if NUM_CLIPPING_PLANES > 0\n\t#if ! defined( PHYSICAL ) && ! defined( PHONG )\n\t\tvarying vec3 vViewPosition;\n\t#endif\n\tuniform vec4 cs[ NUM_CLIPPING_PLANES ];\n#endif\n",
			clipping_planes_pars_vertex: "#if NUM_CLIPPING_PLANES > 0 && ! defined( PHYSICAL ) && ! defined( PHONG )\n\tvarying vec3 vViewPosition;\n#endif\n",
			clipping_planes_vertex: "#if NUM_CLIPPING_PLANES > 0 && ! defined( PHYSICAL ) && ! defined( PHONG )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n",
			color_fragment: "#ifdef USE_COLOR\n\tdiffuseColor.rgb *= vColor;\n#endif",
			color_pars_fragment: "#ifdef USE_COLOR\n\tvarying vec3 vColor;\n#endif\n",
			color_pars_vertex: "#ifdef USE_COLOR\n\tvarying vec3 vColor;\n#endif",
			color_vertex: "#ifdef USE_COLOR\n\tvColor.xyz = color.xyz;\n#endif",
			common: "#define PI 3.14159265359\n#define PI2 6.28318530718\n#define PI_HALF 1.5707963267949\n#define RECIPROCAL_PI 0.31830988618\n#define RECIPROCAL_PI2 0.15915494\n#define LOG2 1.442695\n#define EPSILON 1e-6\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#define whiteCompliment(a) ( 1.0 - saturate( a ) )\nfloat pow2( const in float x ) { return x*x; }\nfloat pow3( const in float x ) { return x*x*x; }\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\nhighp float rand( const in vec2 uv ) {\n\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\n\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\n\treturn fract(sin(sn) * c);\n}\nstruct IncidentLight {\n\tvec3 color;\n\tvec3 direction;\n\tbool visible;\n};\nstruct ReflectedLight {\n\tvec3 directDiffuse;\n\tvec3 directSpecular;\n\tvec3 indirectDiffuse;\n\tvec3 indirectSpecular;\n};\nstruct GeometricContext {\n\tvec3 position;\n\tvec3 normal;\n\tvec3 viewDir;\n};\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\n}\nvec3 projectOnPlane(in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\tfloat distance = dot( planeNormal, point - pointOnPlane );\n\treturn - distance * planeNormal + point;\n}\nfloat sideOfPlane( in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn sign( dot( point - pointOnPlane, planeNormal ) );\n}\nvec3 linePlaneIntersect( in vec3 pointOnLine, in vec3 lineDirection, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn lineDirection * ( dot( planeNormal, pointOnPlane - pointOnLine ) / dot( planeNormal, lineDirection ) ) + pointOnLine;\n}\nmat3 transposeMat3( const in mat3 m ) {\n\tmat3 tmp;\n\ttmp[ 0 ] = vec3( m[ 0 ].x, m[ 1 ].x, m[ 2 ].x );\n\ttmp[ 1 ] = vec3( m[ 0 ].y, m[ 1 ].y, m[ 2 ].y );\n\ttmp[ 2 ] = vec3( m[ 0 ].z, m[ 1 ].z, m[ 2 ].z );\n\treturn tmp;\n}\nfloat linearToRelativeLuminance( const in vec3 color ) {\n\tvec3 weights = vec3( 0.2126, 0.7152, 0.0722 );\n\treturn dot( weights, color.rgb );\n}\n",
			cube_uv_reflection_fragment: "#ifdef ENVMAP_TYPE_CUBE_UV\n#define cubeUV_textureSize (1024.0)\nint getFaceFromDirection(vec3 direction) {\n\tvec3 absDirection = abs(direction);\n\tint face = -1;\n\tif( absDirection.x > absDirection.z ) {\n\t\tif(absDirection.x > absDirection.y )\n\t\t\tface = direction.x > 0.0 ? 0 : 3;\n\t\telse\n\t\t\tface = direction.y > 0.0 ? 1 : 4;\n\t}\n\telse {\n\t\tif(absDirection.z > absDirection.y )\n\t\t\tface = direction.z > 0.0 ? 2 : 5;\n\t\telse\n\t\t\tface = direction.y > 0.0 ? 1 : 4;\n\t}\n\treturn face;\n}\n#define cubeUV_maxLods1  (log2(cubeUV_textureSize*0.25) - 1.0)\n#define cubeUV_rangeClamp (exp2((6.0 - 1.0) * 2.0))\nvec2 MipLevelInfo( vec3 vec, float roughnessLevel, float roughness ) {\n\tfloat scale = exp2(cubeUV_maxLods1 - roughnessLevel);\n\tfloat dxRoughness = dFdx(roughness);\n\tfloat dyRoughness = dFdy(roughness);\n\tvec3 dx = dFdx( vec * scale * dxRoughness );\n\tvec3 dy = dFdy( vec * scale * dyRoughness );\n\tfloat d = max( dot( dx, dx ), dot( dy, dy ) );\n\td = clamp(d, 1.0, cubeUV_rangeClamp);\n\tfloat mipLevel = 0.5 * log2(d);\n\treturn vec2(floor(mipLevel), fract(mipLevel));\n}\n#define cubeUV_maxLods2 (log2(cubeUV_textureSize*0.25) - 2.0)\n#define cubeUV_rcpTextureSize (1.0 / cubeUV_textureSize)\nvec2 getCubeUV(vec3 direction, float roughnessLevel, float mipLevel) {\n\tmipLevel = roughnessLevel > cubeUV_maxLods2 - 3.0 ? 0.0 : mipLevel;\n\tfloat a = 16.0 * cubeUV_rcpTextureSize;\n\tvec2 exp2_packed = exp2( vec2( roughnessLevel, mipLevel ) );\n\tvec2 rcp_exp2_packed = vec2( 1.0 ) / exp2_packed;\n\tfloat powScale = exp2_packed.x * exp2_packed.y;\n\tfloat scale = rcp_exp2_packed.x * rcp_exp2_packed.y * 0.25;\n\tfloat mipOffset = 0.75*(1.0 - rcp_exp2_packed.y) * rcp_exp2_packed.x;\n\tbool bRes = mipLevel == 0.0;\n\tscale =  bRes && (scale < a) ? a : scale;\n\tvec3 r;\n\tvec2 offset;\n\tint face = getFaceFromDirection(direction);\n\tfloat rcpPowScale = 1.0 / powScale;\n\tif( face == 0) {\n\t\tr = vec3(direction.x, -direction.z, direction.y);\n\t\toffset = vec2(0.0+mipOffset,0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 1) {\n\t\tr = vec3(direction.y, direction.x, direction.z);\n\t\toffset = vec2(scale+mipOffset, 0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 2) {\n\t\tr = vec3(direction.z, direction.x, direction.y);\n\t\toffset = vec2(2.0*scale+mipOffset, 0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 3) {\n\t\tr = vec3(direction.x, direction.z, direction.y);\n\t\toffset = vec2(0.0+mipOffset,0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\telse if( face == 4) {\n\t\tr = vec3(direction.y, direction.x, -direction.z);\n\t\toffset = vec2(scale+mipOffset, 0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\telse {\n\t\tr = vec3(direction.z, -direction.x, direction.y);\n\t\toffset = vec2(2.0*scale+mipOffset, 0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\tr = normalize(r);\n\tfloat texelOffset = 0.5 * cubeUV_rcpTextureSize;\n\tvec2 s = ( r.yz / abs( r.x ) + vec2( 1.0 ) ) * 0.5;\n\tvec2 base = offset + vec2( texelOffset );\n\treturn base + s * ( scale - 2.0 * texelOffset );\n}\n#define cubeUV_maxLods3 (log2(cubeUV_textureSize*0.25) - 3.0)\nvec4 textureCubeUV(vec3 reflectedDirection, float roughness ) {\n\tfloat roughnessVal = roughness* cubeUV_maxLods3;\n\tfloat r1 = floor(roughnessVal);\n\tfloat r2 = r1 + 1.0;\n\tfloat t = fract(roughnessVal);\n\tvec2 mipInfo = MipLevelInfo(reflectedDirection, r1, roughness);\n\tfloat s = mipInfo.y;\n\tfloat level0 = mipInfo.x;\n\tfloat level1 = level0 + 1.0;\n\tlevel1 = level1 > 5.0 ? 5.0 : level1;\n\tlevel0 += min( floor( s + 0.5 ), 5.0 );\n\tvec2 uv_10 = getCubeUV(reflectedDirection, r1, level0);\n\tvec4 color10 = envMapTexelToLinear(texture2D(envMap, uv_10));\n\tvec2 uv_20 = getCubeUV(reflectedDirection, r2, level0);\n\tvec4 color20 = envMapTexelToLinear(texture2D(envMap, uv_20));\n\tvec4 result = mix(color10, color20, t);\n\treturn vec4(result.rgb, 1.0);\n}\n#endif\n",
			defaultnormal_vertex: "vec3 transformedNormal = normalMatrix * objectNormal;\n#ifdef FLIP_SIDED\n\ttransformedNormal = - transformedNormal;\n#endif\n",
			displacementmap_pars_vertex: "#ifdef USE_DISPLACEMENTMAP\n\tuniform sampler2D displacementMap;\n\tuniform float displacementScale;\n\tuniform float displacementBias;\n#endif\n",
			displacementmap_vertex: "#ifdef USE_DISPLACEMENTMAP\n\ttransformed += normalize( objectNormal ) * ( texture2D( displacementMap, uv ).x * displacementScale + displacementBias );\n#endif\n",
			emissivemap_fragment: "#ifdef USE_EMISSIVEMAP\n\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\n\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\n\ttotalEmissiveRadiance *= emissiveColor.rgb;\n#endif\n",
			emissivemap_pars_fragment: "#ifdef USE_EMISSIVEMAP\n\tuniform sampler2D emissiveMap;\n#endif\n",
			encodings_fragment: "  gl_FragColor = linearToOutputTexel( gl_FragColor );\n",
			encodings_pars_fragment: "\nvec4 LinearToLinear( in vec4 value ) {\n\treturn value;\n}\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.xyz, vec3( gammaFactor ) ), value.w );\n}\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.xyz, vec3( 1.0 / gammaFactor ) ), value.w );\n}\nvec4 sRGBToLinear( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.w );\n}\nvec4 LinearTosRGB( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.w );\n}\nvec4 RGBEToLinear( in vec4 value ) {\n\treturn vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\n}\nvec4 LinearToRGBE( in vec4 value ) {\n\tfloat maxComponent = max( max( value.r, value.g ), value.b );\n\tfloat fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\n\treturn vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\n}\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.xyz * value.w * maxRange, 1.0 );\n}\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.x, max( value.g, value.b ) );\n\tfloat M      = clamp( maxRGB / maxRange, 0.0, 1.0 );\n\tM            = ceil( M * 255.0 ) / 255.0;\n\treturn vec4( value.rgb / ( M * maxRange ), M );\n}\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\n}\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.x, max( value.g, value.b ) );\n\tfloat D      = max( maxRange / maxRGB, 1.0 );\n\tD            = min( floor( D ) / 255.0, 1.0 );\n\treturn vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\n}\nconst mat3 cLogLuvM = mat3( 0.2209, 0.3390, 0.4184, 0.1138, 0.6780, 0.7319, 0.0102, 0.1130, 0.2969 );\nvec4 LinearToLogLuv( in vec4 value )  {\n\tvec3 Xp_Y_XYZp = value.rgb * cLogLuvM;\n\tXp_Y_XYZp = max(Xp_Y_XYZp, vec3(1e-6, 1e-6, 1e-6));\n\tvec4 vResult;\n\tvResult.xy = Xp_Y_XYZp.xy / Xp_Y_XYZp.z;\n\tfloat Le = 2.0 * log2(Xp_Y_XYZp.y) + 127.0;\n\tvResult.w = fract(Le);\n\tvResult.z = (Le - (floor(vResult.w*255.0))/255.0)/255.0;\n\treturn vResult;\n}\nconst mat3 cLogLuvInverseM = mat3( 6.0014, -2.7008, -1.7996, -1.3320, 3.1029, -5.7721, 0.3008, -1.0882, 5.6268 );\nvec4 LogLuvToLinear( in vec4 value ) {\n\tfloat Le = value.z * 255.0 + value.w;\n\tvec3 Xp_Y_XYZp;\n\tXp_Y_XYZp.y = exp2((Le - 127.0) / 2.0);\n\tXp_Y_XYZp.z = Xp_Y_XYZp.y / value.y;\n\tXp_Y_XYZp.x = value.x * Xp_Y_XYZp.z;\n\tvec3 vRGB = Xp_Y_XYZp.rgb * cLogLuvInverseM;\n\treturn vec4( max(vRGB, 0.0), 1.0 );\n}\n",
			envmap_fragment: "#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvec3 cameraToVertex = normalize( vWorldPosition - cameraPosition );\n\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#else\n\t\tvec3 reflectVec = vReflect;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tvec4 envColor = textureCube( envMap, vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\n\t#elif defined( ENVMAP_TYPE_EQUIREC )\n\t\tvec2 sampleUV;\n\t\treflectVec = normalize( reflectVec );\n\t\tsampleUV.y = asin( clamp( reflectVec.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\n\t\tsampleUV.x = atan( reflectVec.z, reflectVec.x ) * RECIPROCAL_PI2 + 0.5;\n\t\tvec4 envColor = texture2D( envMap, sampleUV );\n\t#elif defined( ENVMAP_TYPE_SPHERE )\n\t\treflectVec = normalize( reflectVec );\n\t\tvec3 reflectView = normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0, 0.0, 1.0 ) );\n\t\tvec4 envColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5 );\n\t#else\n\t\tvec4 envColor = vec4( 0.0 );\n\t#endif\n\tenvColor = envMapTexelToLinear( envColor );\n\t#ifdef ENVMAP_BLENDING_MULTIPLY\n\t\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_MIX )\n\t\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_ADD )\n\t\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\n\t#endif\n#endif\n",
			envmap_pars_fragment: "#if defined( USE_ENVMAP ) || defined( PHYSICAL )\n\tuniform float reflectivity;\n\tuniform float envMapIntensity;\n#endif\n#ifdef USE_ENVMAP\n\t#if ! defined( PHYSICAL ) && ( defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG ) )\n\t\tvarying vec3 vWorldPosition;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tuniform samplerCube envMap;\n\t#else\n\t\tuniform sampler2D envMap;\n\t#endif\n\tuniform float flipEnvMap;\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG ) || defined( PHYSICAL )\n\t\tuniform float refractionRatio;\n\t#else\n\t\tvarying vec3 vReflect;\n\t#endif\n#endif\n",
			envmap_pars_vertex: "#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvarying vec3 vWorldPosition;\n\t#else\n\t\tvarying vec3 vReflect;\n\t\tuniform float refractionRatio;\n\t#endif\n#endif\n",
			envmap_vertex: "#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvWorldPosition = worldPosition.xyz;\n\t#else\n\t\tvec3 cameraToVertex = normalize( worldPosition.xyz - cameraPosition );\n\t\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvReflect = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#endif\n#endif\n",
			fog_vertex: "\n#ifdef USE_FOG\nfogDepth = -mvPosition.z;\n#endif",
			fog_pars_vertex: "#ifdef USE_FOG\n  varying float fogDepth;\n#endif\n",
			fog_fragment: "#ifdef USE_FOG\n\t#ifdef FOG_EXP2\n\t\tfloat fogFactor = whiteCompliment( exp2( - fogDensity * fogDensity * fogDepth * fogDepth * LOG2 ) );\n\t#else\n\t\tfloat fogFactor = smoothstep( fogNear, fogFar, fogDepth );\n\t#endif\n\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n#endif\n",
			fog_pars_fragment: "#ifdef USE_FOG\n\tuniform vec3 fogColor;\n\tvarying float fogDepth;\n\t#ifdef FOG_EXP2\n\t\tuniform float fogDensity;\n\t#else\n\t\tuniform float fogNear;\n\t\tuniform float fogFar;\n\t#endif\n#endif\n",
			gradientmap_pars_fragment: "#ifdef TOON\n\tuniform sampler2D gradientMap;\n\tvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\n\t\tfloat dotNL = dot( normal, lightDirection );\n\t\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\n\t\t#ifdef USE_GRADIENTMAP\n\t\t\treturn texture2D( gradientMap, coord ).rgb;\n\t\t#else\n\t\t\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\n\t\t#endif\n\t}\n#endif\n",
			lightmap_fragment: "#ifdef USE_LIGHTMAP\n\treflectedLight.indirectDiffuse += PI * texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n#endif\n",
			lightmap_pars_fragment: "#ifdef USE_LIGHTMAP\n\tuniform sampler2D lightMap;\n\tuniform float lightMapIntensity;\n#endif",
			lights_lambert_vertex: "vec3 diffuse = vec3( 1.0 );\nGeometricContext geometry;\ngeometry.position = mvPosition.xyz;\ngeometry.normal = normalize( transformedNormal );\ngeometry.viewDir = normalize( -mvPosition.xyz );\nGeometricContext backGeometry;\nbackGeometry.position = geometry.position;\nbackGeometry.normal = -geometry.normal;\nbackGeometry.viewDir = geometry.viewDir;\nvLightFront = vec3( 0.0 );\n#ifdef DOUBLE_SIDED\n\tvLightBack = vec3( 0.0 );\n#endif\nIncidentLight directLight;\nfloat dotNL;\nvec3 directLightColor_Diffuse;\n#if NUM_POINT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tgetPointDirectLightIrradiance( pointLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tgetSpotDirectLightIrradiance( spotLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_DIR_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tgetDirectionalDirectLightIrradiance( directionalLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\tvLightFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry );\n\t\t#endif\n\t}\n#endif\n",
			lights_pars: "uniform vec3 ambientLightColor;\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\n\tvec3 irradiance = ambientLightColor;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treturn irradiance;\n}\n#if NUM_DIR_LIGHTS > 0\n\tstruct Dt {\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform Dt directionalLights[ NUM_DIR_LIGHTS ];\n\tvoid getDirectionalDirectLightIrradiance( const in Dt directionalLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tdirectLight.color = directionalLight.color;\n\t\tdirectLight.direction = directionalLight.direction;\n\t\tdirectLight.visible = true;\n\t}\n#endif\n#if NUM_POINT_LIGHTS > 0\n\tstruct PointLight {\n\t\tvec3 position;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t\tfloat shadowCameraNear;\n\t\tfloat shadowCameraFar;\n\t};\n\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\n\tvoid getPointDirectLightIrradiance( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = pointLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tdirectLight.color = pointLight.color;\n\t\tdirectLight.color *= punctualLightIntensityToIrradianceFactor( lightDistance, pointLight.distance, pointLight.decay );\n\t\tdirectLight.visible = ( directLight.color != vec3( 0.0 ) );\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tstruct SpotLight {\n\t\tvec3 position;\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tfloat coneCos;\n\t\tfloat penumbraCos;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\n\tvoid getSpotDirectLightIrradiance( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight directLight  ) {\n\t\tvec3 lVector = spotLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tfloat angleCos = dot( directLight.direction, spotLight.direction );\n\t\tif ( angleCos > spotLight.coneCos ) {\n\t\t\tfloat spotEffect = smoothstep( spotLight.coneCos, spotLight.penumbraCos, angleCos );\n\t\t\tdirectLight.color = spotLight.color;\n\t\t\tdirectLight.color *= spotEffect * punctualLightIntensityToIrradianceFactor( lightDistance, spotLight.distance, spotLight.decay );\n\t\t\tdirectLight.visible = true;\n\t\t} else {\n\t\t\tdirectLight.color = vec3( 0.0 );\n\t\t\tdirectLight.visible = false;\n\t\t}\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tstruct RectAreaLight {\n\t\tvec3 color;\n\t\tvec3 position;\n\t\tvec3 halfWidth;\n\t\tvec3 halfHeight;\n\t};\n\tuniform sampler2D ltcMat;\tuniform sampler2D ltcMag;\n\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tstruct HemisphereLight {\n\t\tvec3 direction;\n\t\tvec3 skyColor;\n\t\tvec3 groundColor;\n\t};\n\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\n\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in GeometricContext geometry ) {\n\t\tfloat dotNL = dot( geometry.normal, hemiLight.direction );\n\t\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\n\t\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tirradiance *= PI;\n\t\t#endif\n\t\treturn irradiance;\n\t}\n#endif\n#if defined( USE_ENVMAP ) && defined( PHYSICAL )\n\tvec3 getLightProbeIndirectIrradiance( const in GeometricContext geometry, const in int maxMIPLevel ) {\n\t\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\tvec4 envMapColor = textureCubeUV( queryVec, 1.0 );\n\t\t#else\n\t\t\tvec4 envMapColor = vec4( 0.0 );\n\t\t#endif\n\t\treturn PI * envMapColor.rgb * envMapIntensity;\n\t}\n\tfloat getSpecularMIPLevel( const in float blinnShininessExponent, const in int maxMIPLevel ) {\n\t\tfloat maxMIPLevelScalar = float( maxMIPLevel );\n\t\tfloat desiredMIPLevel = maxMIPLevelScalar + 0.79248 - 0.5 * log2( pow2( blinnShininessExponent ) + 1.0 );\n\t\treturn clamp( desiredMIPLevel, 0.0, maxMIPLevelScalar );\n\t}\n\tvec3 getLightProbeIndirectRadiance( const in GeometricContext geometry, const in float blinnShininessExponent, const in int maxMIPLevel ) {\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( -geometry.viewDir, geometry.normal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( -geometry.viewDir, geometry.normal, refractionRatio );\n\t\t#endif\n\t\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\n\t\tfloat specularMIPLevel = getSpecularMIPLevel( blinnShininessExponent, maxMIPLevel );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\tvec4 envMapColor = textureCubeUV(queryReflectVec, BlinnExponentToGGXRoughness(blinnShininessExponent));\n\t\t#elif defined( ENVMAP_TYPE_EQUIREC )\n\t\t\tvec2 sampleUV;\n\t\t\tsampleUV.y = asin( clamp( reflectVec.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\n\t\t\tsampleUV.x = atan( reflectVec.z, reflectVec.x ) * RECIPROCAL_PI2 + 0.5;\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = texture2DLodEXT( envMap, sampleUV, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = texture2D( envMap, sampleUV, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_SPHERE )\n\t\t\tvec3 reflectView = normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0,0.0,1.0 ) );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = texture2DLodEXT( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#endif\n\t\treturn envMapColor.rgb * envMapIntensity;\n\t}\n#endif\n",
			lights_phong_fragment: "BlinnPhongMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;\nmaterial.specularColor = specular;\nmaterial.specularShininess = shininess;\nmaterial.specularStrength = specularStrength;\n",
			lights_phong_pars_fragment: "varying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\nstruct BlinnPhongMaterial {\n\tvec3\tdiffuseColor;\n\tvec3\tspecularColor;\n\tfloat\tspecularShininess;\n\tfloat\tspecularStrength;\n};\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\t#ifdef TOON\n\t\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\n\t#else\n\t\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\t\tvec3 irradiance = dotNL * directLight.color;\n\t#endif\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\treflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;\n}\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_BlinnPhong\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_BlinnPhong\n#define Material_LightProbeLOD( material )\t(0)\n",
			lights_physical_fragment: "PhysicalMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\nmaterial.specularRoughness = clamp( roughnessFactor, 0.04, 1.0 );\n#ifdef STANDARD\n\tmaterial.specularColor = mix( vec3( DEFAULT_SPECULAR_COEFFICIENT ), diffuseColor.rgb, metalnessFactor );\n#else\n\tmaterial.specularColor = mix( vec3( MAXIMUM_SPECULAR_COEFFICIENT * pow2( reflectivity ) ), diffuseColor.rgb, metalnessFactor );\n\tmaterial.clearCoat = saturate( clearCoat );\tmaterial.clearCoatRoughness = clamp( clearCoatRoughness, 0.04, 1.0 );\n#endif\n",
			lights_physical_pars_fragment: "struct PhysicalMaterial {\n\tvec3\tdiffuseColor;\n\tfloat\tspecularRoughness;\n\tvec3\tspecularColor;\n\t#ifndef STANDARD\n\t\tfloat clearCoat;\n\t\tfloat clearCoatRoughness;\n\t#endif\n};\n#define MAXIMUM_SPECULAR_COEFFICIENT 0.16\n#define DEFAULT_SPECULAR_COEFFICIENT 0.04\nfloat clearCoatDHRApprox( const in float roughness, const in float dotNL ) {\n\treturn DEFAULT_SPECULAR_COEFFICIENT + ( 1.0 - DEFAULT_SPECULAR_COEFFICIENT ) * ( pow( 1.0 - dotNL, 5.0 ) * pow( 1.0 - roughness, 2.0 ) );\n}\n#if NUM_RECT_AREA_LIGHTS > 0\n\tvoid RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t\tvec3 normal = geometry.normal;\n\t\tvec3 viewDir = geometry.viewDir;\n\t\tvec3 position = geometry.position;\n\t\tvec3 lightPos = rectAreaLight.position;\n\t\tvec3 halfWidth = rectAreaLight.halfWidth;\n\t\tvec3 halfHeight = rectAreaLight.halfHeight;\n\t\tvec3 lightColor = rectAreaLight.color;\n\t\tfloat roughness = material.specularRoughness;\n\t\tvec3 rectCoords[ 4 ];\n\t\trectCoords[ 0 ] = lightPos - halfWidth - halfHeight;\t\trectCoords[ 1 ] = lightPos + halfWidth - halfHeight;\n\t\trectCoords[ 2 ] = lightPos + halfWidth + halfHeight;\n\t\trectCoords[ 3 ] = lightPos - halfWidth + halfHeight;\n\t\tvec2 uv = LTC_Uv( normal, viewDir, roughness );\n\t\tfloat norm = texture2D( ltcMag, uv ).a;\n\t\tvec4 t = texture2D( ltcMat, uv );\n\t\tmat3 mInv = mat3(\n\t\t\tvec3(   1,   0, t.y ),\n\t\t\tvec3(   0, t.z,   0 ),\n\t\t\tvec3( t.w,   0, t.x )\n\t\t);\n\t\treflectedLight.directSpecular += lightColor * material.specularColor * norm * LTC_Evaluate( normal, viewDir, position, mInv, rectCoords );\n\t\treflectedLight.directDiffuse += lightColor * material.diffuseColor * LTC_Evaluate( normal, viewDir, position, mat3( 1 ), rectCoords );\n\t}\n#endif\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\t#ifndef STANDARD\n\t\tfloat clearCoatDHR = material.clearCoat * clearCoatDHRApprox( material.clearCoatRoughness, dotNL );\n\t#else\n\t\tfloat clearCoatDHR = 0.0;\n\t#endif\n\treflectedLight.directSpecular += ( 1.0 - clearCoatDHR ) * irradiance * BRDF_Specular_GGX( directLight, geometry, material.specularColor, material.specularRoughness );\n\treflectedLight.directDiffuse += ( 1.0 - clearCoatDHR ) * irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\t#ifndef STANDARD\n\t\treflectedLight.directSpecular += irradiance * material.clearCoat * BRDF_Specular_GGX( directLight, geometry, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearCoatRoughness );\n\t#endif\n}\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 clearCoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t#ifndef STANDARD\n\t\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\t\tfloat dotNL = dotNV;\n\t\tfloat clearCoatDHR = material.clearCoat * clearCoatDHRApprox( material.clearCoatRoughness, dotNL );\n\t#else\n\t\tfloat clearCoatDHR = 0.0;\n\t#endif\n\treflectedLight.indirectSpecular += ( 1.0 - clearCoatDHR ) * radiance * BRDF_Specular_GGX_Environment( geometry, material.specularColor, material.specularRoughness );\n\t#ifndef STANDARD\n\t\treflectedLight.indirectSpecular += clearCoatRadiance * material.clearCoat * BRDF_Specular_GGX_Environment( geometry, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearCoatRoughness );\n\t#endif\n}\n#define RE_Direct\t\t\t\tRE_Direct_Physical\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_Physical\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Physical\n#define RE_IndirectSpecular\t\tRE_IndirectSpecular_Physical\n#define Material_BlinnShininessExponent( material )   GGXRoughnessToBlinnExponent( material.specularRoughness )\n#define Material_ClearCoat_BlinnShininessExponent( material )   GGXRoughnessToBlinnExponent( material.clearCoatRoughness )\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\n\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\n}\n",
			lights_template: "\nGeometricContext geometry;\ngeometry.position = - vViewPosition;\ngeometry.normal = normal;\ngeometry.viewDir = normalize( vViewPosition );\nIncidentLight directLight;\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\n\tPointLight pointLight;\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tgetPointDirectLightIrradiance( pointLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( pointLight.shadow, directLight.visible ) ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\n\tSpotLight spotLight;\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tgetSpotDirectLightIrradiance( spotLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( spotLight.shadow, directLight.visible ) ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\n\tDt directionalLight;\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tgetDirectionalDirectLightIrradiance( directionalLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( directionalLight.shadow, directLight.visible ) ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\n\tRectAreaLight rectAreaLight;\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t\trectAreaLight = rectAreaLights[ i ];\n\t\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if defined( RE_IndirectDiffuse )\n\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\n\t#ifdef USE_LIGHTMAP\n\t\tvec3 lightMapIrradiance = texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tlightMapIrradiance *= PI;\n\t\t#endif\n\t\tirradiance += lightMapIrradiance;\n\t#endif\n\t#if ( NUM_HEMI_LIGHTS > 0 )\n\t\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\t\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t}\n\t#endif\n\t#if defined( USE_ENVMAP ) && defined( PHYSICAL ) && defined( ENVMAP_TYPE_CUBE_UV )\n\t\tirradiance += getLightProbeIndirectIrradiance( geometry, 8 );\n\t#endif\n\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\n#endif\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\n\tvec3 radiance = getLightProbeIndirectRadiance( geometry, Material_BlinnShininessExponent( material ), 8 );\n\t#ifndef STANDARD\n\t\tvec3 clearCoatRadiance = getLightProbeIndirectRadiance( geometry, Material_ClearCoat_BlinnShininessExponent( material ), 8 );\n\t#else\n\t\tvec3 clearCoatRadiance = vec3( 0.0 );\n\t#endif\n\tRE_IndirectSpecular( radiance, clearCoatRadiance, geometry, material, reflectedLight );\n#endif\n",
			logdepthbuf_fragment: "#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tgl_FragDepthEXT = log2( vFragDepth ) * logDepthBufFC * 0.5;\n#endif",
			logdepthbuf_pars_fragment: "#ifdef USE_LOGDEPTHBUF\n\tuniform float logDepthBufFC;\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t#endif\n#endif\n",
			logdepthbuf_pars_vertex: "#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t#endif\n\tuniform float logDepthBufFC;\n#endif",
			logdepthbuf_vertex: "#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvFragDepth = 1.0 + gl_Position.w;\n\t#else\n\t\tgl_Position.z = log2( max( EPSILON, gl_Position.w + 1.0 ) ) * logDepthBufFC - 1.0;\n\t\tgl_Position.z *= gl_Position.w;\n\t#endif\n#endif\n",
			map_fragment: "#ifdef USE_MAP\n\tvec4 texelColor = texture2D( map, vUv );\n\ttexelColor = mapTexelToLinear( texelColor );\n\tdiffuseColor *= texelColor;\n#endif\n",
			map_pars_fragment: "#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif\n",
			map_particle_fragment: "#ifdef USE_MAP\n\tvec2 uv = ( uvTransform * vec3( gl_PointCoord.x, 1.0 - gl_PointCoord.y, 1 ) ).xy;\n\tvec4 mapTexel = texture2D( map, uv );\n\tdiffuseColor *= mapTexelToLinear( mapTexel );\n#endif\n",
			map_particle_pars_fragment: "#ifdef USE_MAP\n\tuniform mat3 uvTransform;\n\tuniform sampler2D map;\n#endif\n",
			metalnessmap_fragment: "float metalnessFactor = metalness;\n#ifdef USE_METALNESSMAP\n\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\n\tmetalnessFactor *= texelMetalness.b;\n#endif\n",
			metalnessmap_pars_fragment: "#ifdef USE_METALNESSMAP\n\tuniform sampler2D metalnessMap;\n#endif",
			morphnormal_vertex: "#ifdef USE_MORPHNORMALS\n\tobjectNormal += ( morphNormal0 - normal ) * morphTargetInfluences[ 0 ];\n\tobjectNormal += ( morphNormal1 - normal ) * morphTargetInfluences[ 1 ];\n\tobjectNormal += ( morphNormal2 - normal ) * morphTargetInfluences[ 2 ];\n\tobjectNormal += ( morphNormal3 - normal ) * morphTargetInfluences[ 3 ];\n#endif\n",
			morphtarget_pars_vertex: "#ifdef USE_MORPHTARGETS\n\t#ifndef USE_MORPHNORMALS\n\tuniform float morphTargetInfluences[ 8 ];\n\t#else\n\tuniform float morphTargetInfluences[ 4 ];\n\t#endif\n#endif",
			morphtarget_vertex: "#ifdef USE_MORPHTARGETS\n\ttransformed += ( morphTarget0 - position ) * morphTargetInfluences[ 0 ];\n\ttransformed += ( morphTarget1 - position ) * morphTargetInfluences[ 1 ];\n\ttransformed += ( morphTarget2 - position ) * morphTargetInfluences[ 2 ];\n\ttransformed += ( morphTarget3 - position ) * morphTargetInfluences[ 3 ];\n\t#ifndef USE_MORPHNORMALS\n\ttransformed += ( morphTarget4 - position ) * morphTargetInfluences[ 4 ];\n\ttransformed += ( morphTarget5 - position ) * morphTargetInfluences[ 5 ];\n\ttransformed += ( morphTarget6 - position ) * morphTargetInfluences[ 6 ];\n\ttransformed += ( morphTarget7 - position ) * morphTargetInfluences[ 7 ];\n\t#endif\n#endif\n",
			normal_fragment: "#ifdef FLAT_SHADED\n\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\n\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\n\tvec3 normal = normalize( cross( fdx, fdy ) );\n#else\n\tvec3 normal = normalize( vNormal );\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * ( float( gl_FrontFacing ) * 2.0 - 1.0 );\n\t#endif\n#endif\n#ifdef USE_NORMALMAP\n\tnormal = perturbNormal2Arb( -vViewPosition, normal );\n#elif defined( USE_BUMPMAP )\n\tnormal = perturbNormalArb( -vViewPosition, normal, dHdxy_fwd() );\n#endif\n",
			normalmap_pars_fragment: "#ifdef USE_NORMALMAP\n\tuniform sampler2D normalMap;\n\tuniform vec2 normalScale;\n\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm ) {\n\t\tvec3 q0 = vec3( dFdx( eye_pos.x ), dFdx( eye_pos.y ), dFdx( eye_pos.z ) );\n\t\tvec3 q1 = vec3( dFdy( eye_pos.x ), dFdy( eye_pos.y ), dFdy( eye_pos.z ) );\n\t\tvec2 st0 = dFdx( vUv.st );\n\t\tvec2 st1 = dFdy( vUv.st );\n\t\tvec3 S = normalize( q0 * st1.t - q1 * st0.t );\n\t\tvec3 T = normalize( -q0 * st1.s + q1 * st0.s );\n\t\tvec3 N = normalize( surf_norm );\n\t\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\t\tmapN.xy = normalScale * mapN.xy;\n\t\tmat3 tsn = mat3( S, T, N );\n\t\treturn normalize( tsn * mapN );\n\t}\n#endif\n",
			packing: "vec3 packNormalToRGB( const in vec3 normal ) {\n\treturn normalize( normal ) * 0.5 + 0.5;\n}\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\n\treturn 2.0 * rgb.xyz - 1.0;\n}\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256.,  256. );\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\nconst float ShiftRight8 = 1. / 256.;\nvec4 packDepthToRGBA( const in float v ) {\n\tvec4 r = vec4( fract( v * PackFactors ), v );\n\tr.yzw -= r.xyz * ShiftRight8;\treturn r * PackUpscale;\n}\nfloat unpackRGBAToDepth( const in vec4 v ) {\n\treturn dot( v, UnpackFactors );\n}\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn ( viewZ + near ) / ( near - far );\n}\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\n\treturn linearClipZ * ( near - far ) - near;\n}\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn (( near + viewZ ) * far ) / (( far - near ) * viewZ );\n}\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\n\treturn ( near * far ) / ( ( far - near ) * invClipZ - far );\n}\n",
			premultiplied_alpha_fragment: "#ifdef PREMULTIPLIED_ALPHA\n\tgl_FragColor.rgb *= gl_FragColor.a;\n#endif\n",
			project_vertex: "vec4 mvPosition = modelViewMatrix * vec4( transformed, 1.0 );\ngl_Position = projectionMatrix * mvPosition;\n",
			dithering_fragment: "#if defined( DITHERING )\n  gl_FragColor.rgb = dithering( gl_FragColor.rgb );\n#endif\n",
			dithering_pars_fragment: "#if defined( DITHERING )\n\tvec3 dithering( vec3 color ) {\n\t\tfloat grid_position = rand( gl_FragCoord.xy );\n\t\tvec3 dither_shift_RGB = vec3( 0.25 / 255.0, -0.25 / 255.0, 0.25 / 255.0 );\n\t\tdither_shift_RGB = mix( 2.0 * dither_shift_RGB, -2.0 * dither_shift_RGB, grid_position );\n\t\treturn color + dither_shift_RGB;\n\t}\n#endif\n",
			roughnessmap_fragment: "float roughnessFactor = roughness;\n#ifdef USE_ROUGHNESSMAP\n\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\n\troughnessFactor *= texelRoughness.g;\n#endif\n",
			roughnessmap_pars_fragment: "#ifdef USE_ROUGHNESSMAP\n\tuniform sampler2D roughnessMap;\n#endif",
			shadowmap_pars_fragment: "#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\t\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHTS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHTS ];\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\t\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHTS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHTS ];\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\t\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHTS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHTS ];\n\t#endif\n\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\n\t\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\n\t}\n\tfloat texture2DShadowLerp( sampler2D depths, vec2 size, vec2 uv, float compare ) {\n\t\tconst vec2 offset = vec2( 0.0, 1.0 );\n\t\tvec2 texelSize = vec2( 1.0 ) / size;\n\t\tvec2 centroidUV = floor( uv * size + 0.5 ) / size;\n\t\tfloat lb = texture2DCompare( depths, centroidUV + texelSize * offset.xx, compare );\n\t\tfloat lt = texture2DCompare( depths, centroidUV + texelSize * offset.xy, compare );\n\t\tfloat rb = texture2DCompare( depths, centroidUV + texelSize * offset.yx, compare );\n\t\tfloat rt = texture2DCompare( depths, centroidUV + texelSize * offset.yy, compare );\n\t\tvec2 f = fract( uv * size + 0.5 );\n\t\tfloat a = mix( lb, lt, f.y );\n\t\tfloat b = mix( rb, rt, f.y );\n\t\tfloat c = mix( a, b, f.x );\n\t\treturn c;\n\t}\n\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tfloat shadow = 1.0;\n\t\tshadowCoord.xyz /= shadowCoord.w;\n\t\tshadowCoord.z += shadowBias;\n\t\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\n\t\tbool inFrustum = all( inFrustumVec );\n\t\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\n\t\tbool frustumTest = all( frustumTestVec );\n\t\tif ( frustumTest ) {\n\t\t#if defined( SHADOWMAP_TYPE_PCF )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\tshadow = (\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\tshadow = texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#endif\n\t\t}\n\t\treturn shadow;\n\t}\n\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\n\t\tvec3 absV = abs( v );\n\t\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\n\t\tabsV *= scaleToCube;\n\t\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\n\t\tvec2 planar = v.xy;\n\t\tfloat almostATexel = 1.5 * texelSizeY;\n\t\tfloat almostOne = 1.0 - almostATexel;\n\t\tif ( absV.z >= almostOne ) {\n\t\t\tif ( v.z > 0.0 )\n\t\t\t\tplanar.x = 4.0 - v.x;\n\t\t} else if ( absV.x >= almostOne ) {\n\t\t\tfloat signX = sign( v.x );\n\t\t\tplanar.x = v.z * signX + 2.0 * signX;\n\t\t} else if ( absV.y >= almostOne ) {\n\t\t\tfloat signY = sign( v.y );\n\t\t\tplanar.x = v.x + 2.0 * signY + 2.0;\n\t\t\tplanar.y = v.z * signY - 2.0;\n\t\t}\n\t\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\n\t}\n\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord, float shadowCameraNear, float shadowCameraFar ) {\n\t\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\n\t\tvec3 lightToPosition = shadowCoord.xyz;\n\t\tfloat dp = ( length( lightToPosition ) - shadowCameraNear ) / ( shadowCameraFar - shadowCameraNear );\t\tdp += shadowBias;\n\t\tvec3 bd3D = normalize( lightToPosition );\n\t\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\n\t\t#endif\n\t}\n#endif\n",
			shadowmap_pars_vertex: "#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\t\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHTS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHTS ];\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\t\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHTS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHTS ];\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\t\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHTS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHTS ];\n\t#endif\n#endif\n",
			shadowmap_vertex: "#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n#endif\n",
			shadowmask_pars_fragment: "float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\tDt directionalLight;\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tshadow *= bool( directionalLight.shadow ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\tSpotLight spotLight;\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tshadow *= bool( spotLight.shadow ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\tPointLight pointLight;\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tshadow *= bool( pointLight.shadow ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\n\t}\n\t#endif\n\t#endif\n\treturn shadow;\n}\n",
			skinbase_vertex: "#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",
			skinning_pars_vertex: "#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform sampler2D boneTexture;\n\t\tuniform int boneTextureSize;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureSize ) );\n\t\t\tfloat y = floor( j / float( boneTextureSize ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureSize );\n\t\t\tfloat dy = 1.0 / float( boneTextureSize );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif\n",
			skinning_vertex: "#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\ttransformed = ( bindMatrixInverse * skinned ).xyz;\n#endif\n",
			skinnormal_vertex: "#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix  = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n#endif\n",
			specularmap_fragment: "float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",
			specularmap_pars_fragment: "#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",
			tonemapping_fragment: "#if defined( TONE_MAPPING )\n  gl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif\n",
			tonemapping_pars_fragment: "#ifndef saturate\n\t#define saturate(a) clamp( a, 0.0, 1.0 )\n#endif\nuniform float toneMappingExposure;\nuniform float toneMappingWhitePoint;\nvec3 LinearToneMapping( vec3 color ) {\n\treturn toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( color / ( vec3( 1.0 ) + color ) );\n}\n#define Uncharted2Helper( x ) max( ( ( x * ( 0.15 * x + 0.10 * 0.50 ) + 0.20 * 0.02 ) / ( x * ( 0.15 * x + 0.50 ) + 0.20 * 0.30 ) ) - 0.02 / 0.30, vec3( 0.0 ) )\nvec3 Uncharted2ToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( Uncharted2Helper( color ) / Uncharted2Helper( vec3( toneMappingWhitePoint ) ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\tcolor = max( vec3( 0.0 ), color - 0.004 );\n\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\n",
			uv_pars_fragment: "#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvarying vec2 vUv;\n#endif",
			uv_pars_vertex: "#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvarying vec2 vUv;\n\tuniform mat3 uvTransform;\n#endif\n",
			uv_vertex: "#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n#endif",
			uv2_pars_fragment: "#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",
			uv2_pars_vertex: "#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n#endif",
			uv2_vertex: "#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = uv2;\n#endif",
			worldpos_vertex: "#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP )\n\tvec4 worldPosition = modelMatrix * vec4( transformed, 1.0 );\n#endif\n",
			cube_frag: "uniform samplerCube tCube;\nuniform float tFlip;\nuniform float opacity;\nvarying vec3 vWorldPosition;\nvoid main() {\n\tgl_FragColor = textureCube( tCube, vec3( tFlip * vWorldPosition.x, vWorldPosition.yz ) );\n\tgl_FragColor.a *= opacity;\n}\n",
			cube_vert: "varying vec3 vWorldPosition;\n#include <common>\nvoid main() {\n\tvWorldPosition = transformDirection( position, modelMatrix );\n\t#include <begin_vertex>\n\t#include <project_vertex>\n\tgl_Position.z = gl_Position.w;\n}\n",
			depth_frag: "#if DEPTH_PACKING == 3200\n\tuniform float opacity;\n#endif\n#include <common>\n#include <packing>\n#include <uv_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec4 diffuseColor = vec4( 1.0 );\n\t#if DEPTH_PACKING == 3200\n\t\tdiffuseColor.a = opacity;\n\t#endif\n\t#include <map_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\t#include <logdepthbuf_fragment>\n\t#if DEPTH_PACKING == 3200\n\t\tgl_FragColor = vec4( vec3( gl_FragCoord.z ), opacity );\n\t#elif DEPTH_PACKING == 3201\n\t\tgl_FragColor = packDepthToRGBA( gl_FragCoord.z );\n\t#endif\n}\n",
			depth_vert: "#include <common>\n#include <uv_pars_vertex>\n#include <displacementmap_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <skinbase_vertex>\n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include <beginnormal_vertex>\n\t\t#include <morphnormal_vertex>\n\t\t#include <skinnormal_vertex>\n\t#endif\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <displacementmap_vertex>\n\t#include <project_vertex>\n\t#include <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n}\n",
			distanceRGBA_frag: "#define DISTANCE\nuniform vec3 referencePosition;\nuniform float nearDistance;\nuniform float farDistance;\nvarying vec3 vWorldPosition;\n#include <common>\n#include <packing>\n#include <uv_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main () {\n\t#include <clipping_planes_fragment>\n\tvec4 diffuseColor = vec4( 1.0 );\n\t#include <map_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\tfloat dist = length( vWorldPosition - referencePosition );\n\tdist = ( dist - nearDistance ) / ( farDistance - nearDistance );\n\tdist = saturate( dist );\n\tgl_FragColor = packDepthToRGBA( dist );\n}\n",
			distanceRGBA_vert: "#define DISTANCE\nvarying vec3 vWorldPosition;\n#include <common>\n#include <uv_pars_vertex>\n#include <displacementmap_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <skinbase_vertex>\n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include <beginnormal_vertex>\n\t\t#include <morphnormal_vertex>\n\t\t#include <skinnormal_vertex>\n\t#endif\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <displacementmap_vertex>\n\t#include <project_vertex>\n\t#include <worldpos_vertex>\n\t#include <clipping_planes_vertex>\n\tvWorldPosition = worldPosition.xyz;\n}\n",
			equirect_frag: "uniform sampler2D tEquirect;\nvarying vec3 vWorldPosition;\n#include <common>\nvoid main() {\n\tvec3 direction = normalize( vWorldPosition );\n\tvec2 sampleUV;\n\tsampleUV.y = asin( clamp( direction.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\n\tsampleUV.x = atan( direction.z, direction.x ) * RECIPROCAL_PI2 + 0.5;\n\tgl_FragColor = texture2D( tEquirect, sampleUV );\n}\n",
			equirect_vert: "varying vec3 vWorldPosition;\n#include <common>\nvoid main() {\n\tvWorldPosition = transformDirection( position, modelMatrix );\n\t#include <begin_vertex>\n\t#include <project_vertex>\n}\n",
			linedashed_frag: "uniform vec3 diffuse;\nuniform float opacity;\nuniform float dashSize;\nuniform float totalSize;\nvarying float vLineDistance;\n#include <common>\n#include <color_pars_fragment>\n#include <fog_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\n\t\tdiscard;\n\t}\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include <logdepthbuf_fragment>\n\t#include <color_fragment>\n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <premultiplied_alpha_fragment>\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n}\n",
			linedashed_vert: "uniform float scale;\nattribute float lineDistance;\nvarying float vLineDistance;\n#include <common>\n#include <color_pars_vertex>\n#include <fog_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <color_vertex>\n\tvLineDistance = scale * lineDistance;\n\tvec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n\t#include <fog_vertex>\n}\n",
			meshbasic_frag: "uniform vec3 diffuse;\nuniform float opacity;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include <common>\n#include <color_pars_fragment>\n#include <uv_pars_fragment>\n#include <uv2_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <aomap_pars_fragment>\n#include <lightmap_pars_fragment>\n#include <envmap_pars_fragment>\n#include <fog_pars_fragment>\n#include <specularmap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include <logdepthbuf_fragment>\n\t#include <map_fragment>\n\t#include <color_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\t#include <specularmap_fragment>\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\t#ifdef USE_LIGHTMAP\n\t\treflectedLight.indirectDiffuse += texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n\t#else\n\t\treflectedLight.indirectDiffuse += vec3( 1.0 );\n\t#endif\n\t#include <aomap_fragment>\n\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\n\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\n\t#include <envmap_fragment>\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <premultiplied_alpha_fragment>\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n}\n",
			meshbasic_vert: "#include <common>\n#include <uv_pars_vertex>\n#include <uv2_pars_vertex>\n#include <envmap_pars_vertex>\n#include <color_pars_vertex>\n#include <fog_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <uv2_vertex>\n\t#include <color_vertex>\n\t#include <skinbase_vertex>\n\t#ifdef USE_ENVMAP\n\t#include <beginnormal_vertex>\n\t#include <morphnormal_vertex>\n\t#include <skinnormal_vertex>\n\t#include <defaultnormal_vertex>\n\t#endif\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <project_vertex>\n\t#include <logdepthbuf_vertex>\n\t#include <worldpos_vertex>\n\t#include <clipping_planes_vertex>\n\t#include <envmap_vertex>\n\t#include <fog_vertex>\n}\n",
			meshlambert_frag: "uniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\nvarying vec3 vLightFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n#endif\n#include <common>\n#include <packing>\n#include <dithering_pars_fragment>\n#include <color_pars_fragment>\n#include <uv_pars_fragment>\n#include <uv2_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <aomap_pars_fragment>\n#include <lightmap_pars_fragment>\n#include <emissivemap_pars_fragment>\n#include <envmap_pars_fragment>\n#include <bsdfs>\n#include <lights_pars>\n#include <fog_pars_fragment>\n#include <shadowmap_pars_fragment>\n#include <shadowmask_pars_fragment>\n#include <specularmap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include <logdepthbuf_fragment>\n\t#include <map_fragment>\n\t#include <color_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\t#include <specularmap_fragment>\n\t#include <emissivemap_fragment>\n\treflectedLight.indirectDiffuse = getAmbientLightIrradiance( ambientLightColor );\n\t#include <lightmap_fragment>\n\treflectedLight.indirectDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb );\n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\n\t#else\n\t\treflectedLight.directDiffuse = vLightFront;\n\t#endif\n\treflectedLight.directDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb ) * getShadowMask();\n\t#include <aomap_fragment>\n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include <envmap_fragment>\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n\t#include <premultiplied_alpha_fragment>\n\t#include <dithering_fragment>\n}\n",
			meshlambert_vert: "#define LAMBERT\nvarying vec3 vLightFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n#endif\n#include <common>\n#include <uv_pars_vertex>\n#include <uv2_pars_vertex>\n#include <envmap_pars_vertex>\n#include <bsdfs>\n#include <lights_pars>\n#include <color_pars_vertex>\n#include <fog_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <shadowmap_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <uv2_vertex>\n\t#include <color_vertex>\n\t#include <beginnormal_vertex>\n\t#include <morphnormal_vertex>\n\t#include <skinbase_vertex>\n\t#include <skinnormal_vertex>\n\t#include <defaultnormal_vertex>\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <project_vertex>\n\t#include <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n\t#include <worldpos_vertex>\n\t#include <envmap_vertex>\n\t#include <lights_lambert_vertex>\n\t#include <shadowmap_vertex>\n\t#include <fog_vertex>\n}\n",
			meshphong_frag: "#define PHONG\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform vec3 specular;\nuniform float shininess;\nuniform float opacity;\n#include <common>\n#include <packing>\n#include <dithering_pars_fragment>\n#include <color_pars_fragment>\n#include <uv_pars_fragment>\n#include <uv2_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <aomap_pars_fragment>\n#include <lightmap_pars_fragment>\n#include <emissivemap_pars_fragment>\n#include <envmap_pars_fragment>\n#include <gradientmap_pars_fragment>\n#include <fog_pars_fragment>\n#include <bsdfs>\n#include <lights_pars>\n#include <lights_phong_pars_fragment>\n#include <shadowmap_pars_fragment>\n#include <bumpmap_pars_fragment>\n#include <normalmap_pars_fragment>\n#include <specularmap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include <logdepthbuf_fragment>\n\t#include <map_fragment>\n\t#include <color_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\t#include <specularmap_fragment>\n\t#include <normal_fragment>\n\t#include <emissivemap_fragment>\n\t#include <lights_phong_fragment>\n\t#include <lights_template>\n\t#include <aomap_fragment>\n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\t#include <envmap_fragment>\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n\t#include <premultiplied_alpha_fragment>\n\t#include <dithering_fragment>\n}\n",
			meshphong_vert: "#define PHONG\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include <common>\n#include <uv_pars_vertex>\n#include <uv2_pars_vertex>\n#include <displacementmap_pars_vertex>\n#include <envmap_pars_vertex>\n#include <color_pars_vertex>\n#include <fog_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <shadowmap_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <uv2_vertex>\n\t#include <color_vertex>\n\t#include <beginnormal_vertex>\n\t#include <morphnormal_vertex>\n\t#include <skinbase_vertex>\n\t#include <skinnormal_vertex>\n\t#include <defaultnormal_vertex>\n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <displacementmap_vertex>\n\t#include <project_vertex>\n\t#include <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n\tvViewPosition = - mvPosition.xyz;\n\t#include <worldpos_vertex>\n\t#include <envmap_vertex>\n\t#include <shadowmap_vertex>\n\t#include <fog_vertex>\n}\n",
			meshphysical_frag: "#define PHYSICAL\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float roughness;\nuniform float metalness;\nuniform float opacity;\n#ifndef STANDARD\n\tuniform float clearCoat;\n\tuniform float clearCoatRoughness;\n#endif\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include <common>\n#include <packing>\n#include <dithering_pars_fragment>\n#include <color_pars_fragment>\n#include <uv_pars_fragment>\n#include <uv2_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <aomap_pars_fragment>\n#include <lightmap_pars_fragment>\n#include <emissivemap_pars_fragment>\n#include <envmap_pars_fragment>\n#include <fog_pars_fragment>\n#include <bsdfs>\n#include <cube_uv_reflection_fragment>\n#include <lights_pars>\n#include <lights_physical_pars_fragment>\n#include <shadowmap_pars_fragment>\n#include <bumpmap_pars_fragment>\n#include <normalmap_pars_fragment>\n#include <roughnessmap_pars_fragment>\n#include <metalnessmap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include <logdepthbuf_fragment>\n\t#include <map_fragment>\n\t#include <color_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\t#include <roughnessmap_fragment>\n\t#include <metalnessmap_fragment>\n\t#include <normal_fragment>\n\t#include <emissivemap_fragment>\n\t#include <lights_physical_fragment>\n\t#include <lights_template>\n\t#include <aomap_fragment>\n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n\t#include <premultiplied_alpha_fragment>\n\t#include <dithering_fragment>\n}\n",
			meshphysical_vert: "#define PHYSICAL\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include <common>\n#include <uv_pars_vertex>\n#include <uv2_pars_vertex>\n#include <displacementmap_pars_vertex>\n#include <color_pars_vertex>\n#include <fog_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <shadowmap_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <uv2_vertex>\n\t#include <color_vertex>\n\t#include <beginnormal_vertex>\n\t#include <morphnormal_vertex>\n\t#include <skinbase_vertex>\n\t#include <skinnormal_vertex>\n\t#include <defaultnormal_vertex>\n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <displacementmap_vertex>\n\t#include <project_vertex>\n\t#include <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n\tvViewPosition = - mvPosition.xyz;\n\t#include <worldpos_vertex>\n\t#include <shadowmap_vertex>\n\t#include <fog_vertex>\n}\n",
			normal_frag: "#define NORMAL\nuniform float opacity;\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include <packing>\n#include <uv_pars_fragment>\n#include <bumpmap_pars_fragment>\n#include <normalmap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\nvoid main() {\n\t#include <logdepthbuf_fragment>\n\t#include <normal_fragment>\n\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\n}\n",
			normal_vert: "#define NORMAL\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include <uv_pars_vertex>\n#include <displacementmap_pars_vertex>\n#include <morphtarget_pars_vertex>\n#include <skinning_pars_vertex>\n#include <logdepthbuf_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\n\t#include <beginnormal_vertex>\n\t#include <morphnormal_vertex>\n\t#include <skinbase_vertex>\n\t#include <skinnormal_vertex>\n\t#include <defaultnormal_vertex>\n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include <begin_vertex>\n\t#include <morphtarget_vertex>\n\t#include <skinning_vertex>\n\t#include <displacementmap_vertex>\n\t#include <project_vertex>\n\t#include <logdepthbuf_vertex>\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n}\n",
			points_frag: "uniform vec3 diffuse;\nuniform float opacity;\n#include <common>\n#include <packing>\n#include <color_pars_fragment>\n#include <map_particle_pars_fragment>\n#include <fog_pars_fragment>\n#include <shadowmap_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include <logdepthbuf_fragment>\n\t#include <map_particle_fragment>\n\t#include <color_fragment>\n\t#include <alphatest_fragment>\n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <premultiplied_alpha_fragment>\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n}\n",
			points_vert: "uniform float size;\nuniform float scale;\n#include <common>\n#include <color_pars_vertex>\n#include <fog_pars_vertex>\n#include <shadowmap_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <color_vertex>\n\t#include <begin_vertex>\n\t#include <project_vertex>\n\t#ifdef USE_SIZEATTENUATION\n\t\tgl_PointSize = size * ( scale / - mvPosition.z );\n\t#else\n\t\tgl_PointSize = size;\n\t#endif\n\t#include <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n\t#include <worldpos_vertex>\n\t#include <shadowmap_vertex>\n\t#include <fog_vertex>\n}\n",
			shadow_frag: "uniform vec3 color;\nuniform float opacity;\n#include <common>\n#include <packing>\n#include <fog_pars_fragment>\n#include <bsdfs>\n#include <lights_pars>\n#include <shadowmap_pars_fragment>\n#include <shadowmask_pars_fragment>\nvoid main() {\n\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\n\t#include <fog_fragment>\n}\n",
			shadow_vert: "#include <fog_pars_vertex>\n#include <shadowmap_pars_vertex>\nvoid main() {\n\t#include <begin_vertex>\n\t#include <project_vertex>\n\t#include <worldpos_vertex>\n\t#include <shadowmap_vertex>\n\t#include <fog_vertex>\n}\n"
		},
		Ya = {
			basic: {
				uniforms: Wa.merge([Ha.common, Ha.specularmap, Ha.envmap, Ha.aomap, Ha.lightmap, Ha.fog]),
				vertexShader: Xa.meshbasic_vert,
				fragmentShader: Xa.meshbasic_frag
			},
			lambert: {
				uniforms: Wa.merge([Ha.common, Ha.specularmap, Ha.envmap, Ha.aomap, Ha.lightmap, Ha.emissivemap, Ha.fog, Ha.lights, {
					emissive: {
						value: new Y(0)
					}
				}]),
				vertexShader: Xa.meshlambert_vert,
				fragmentShader: Xa.meshlambert_frag
			},
			phong: {
				uniforms: Wa.merge([Ha.common, Ha.specularmap, Ha.envmap, Ha.aomap, Ha.lightmap, Ha.emissivemap, Ha.bumpmap, Ha.normalmap, Ha.displacementmap, Ha.gradientmap, Ha.fog, Ha.lights, {
					emissive: {
						value: new Y(0)
					},
					specular: {
						value: new Y(1118481)
					},
					shininess: {
						value: 30
					}
				}]),
				vertexShader: Xa.meshphong_vert,
				fragmentShader: Xa.meshphong_frag
			},
			standard: {
				uniforms: Wa.merge([Ha.common, Ha.envmap, Ha.aomap, Ha.lightmap, Ha.emissivemap, Ha.bumpmap, Ha.normalmap, Ha.displacementmap, Ha.roughnessmap, Ha.metalnessmap, Ha.fog, Ha.lights, {
					emissive: {
						value: new Y(0)
					},
					roughness: {
						value: .5
					},
					metalness: {
						value: .5
					},
					envMapIntensity: {
						value: 1
					}
				}]),
				vertexShader: Xa.meshphysical_vert,
				fragmentShader: Xa.meshphysical_frag
			},
			points: {
				uniforms: Wa.merge([Ha.points, Ha.fog]),
				vertexShader: Xa.points_vert,
				fragmentShader: Xa.points_frag
			},
			dashed: {
				uniforms: Wa.merge([Ha.common, Ha.fog, {
					scale: {
						value: 1
					},
					dashSize: {
						value: 1
					},
					totalSize: {
						value: 2
					}
				}]),
				vertexShader: Xa.linedashed_vert,
				fragmentShader: Xa.linedashed_frag
			},
			depth: {
				uniforms: Wa.merge([Ha.common, Ha.displacementmap]),
				vertexShader: Xa.depth_vert,
				fragmentShader: Xa.depth_frag
			},
			normal: {
				uniforms: Wa.merge([Ha.common, Ha.bumpmap, Ha.normalmap, Ha.displacementmap, {
					opacity: {
						value: 1
					}
				}]),
				vertexShader: Xa.normal_vert,
				fragmentShader: Xa.normal_frag
			},
			cube: {
				uniforms: {
					tCube: {
						value: null
					},
					tFlip: {
						value: -1
					},
					opacity: {
						value: 1
					}
				},
				vertexShader: Xa.cube_vert,
				fragmentShader: Xa.cube_frag
			},
			equirect: {
				uniforms: {
					tEquirect: {
						value: null
					}
				},
				vertexShader: Xa.equirect_vert,
				fragmentShader: Xa.equirect_frag
			},
			distanceRGBA: {
				uniforms: Wa.merge([Ha.common, Ha.displacementmap, {
					referencePosition: {
						value: new a
					},
					nearDistance: {
						value: 1
					},
					farDistance: {
						value: 1e3
					}
				}]),
				vertexShader: Xa.distanceRGBA_vert,
				fragmentShader: Xa.distanceRGBA_frag
			},
			shadow: {
				uniforms: Wa.merge([Ha.lights, Ha.fog, {
					color: {
						value: new Y(0)
					},
					opacity: {
						value: 1
					}
				}]),
				vertexShader: Xa.shadow_vert,
				fragmentShader: Xa.shadow_frag
			}
		};
	Ya.physical = {
		uniforms: Wa.merge([Ya.standard.uniforms, {
			clearCoat: {
				value: 0
			},
			clearCoatRoughness: {
				value: 0
			}
		}]),
		vertexShader: Xa.meshphysical_vert,
		fragmentShader: Xa.meshphysical_frag
	}, Object.assign(q.prototype, {
		set: function(t, e) {
			return this.min.copy(t), this.max.copy(e), this
		},
		setFromPoints: function(t) {
			this.makeEmpty();
			for(var e = 0, n = t.length; e < n; e++) this.expandByPoint(t[e]);
			return this
		},
		setFromCenterAndSize: function() {
			var t = new n;
			return function(e, n) {
				var i = t.copy(n).multiplyScalar(.5);
				return this.min.copy(e).sub(i), this.max.copy(e).add(i), this
			}
		}(),
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.min.copy(t.min), this.max.copy(t.max), this
		},
		makeEmpty: function() {
			return this.min.x = this.min.y = 1 / 0, this.max.x = this.max.y = -1 / 0, this
		},
		isEmpty: function() {
			return this.max.x < this.min.x || this.max.y < this.min.y
		},
		getCenter: function(t) {
			var e = t || new n;
			return this.isEmpty() ? e.set(0, 0) : e.addVectors(this.min, this.max).multiplyScalar(.5)
		},
		getSize: function(t) {
			var e = t || new n;
			return this.isEmpty() ? e.set(0, 0) : e.subVectors(this.max, this.min)
		},
		expandByPoint: function(t) {
			return this.min.min(t), this.max.max(t), this
		},
		expandByVector: function(t) {
			return this.min.sub(t), this.max.add(t), this
		},
		expandByScalar: function(t) {
			return this.min.addScalar(-t), this.max.addScalar(t), this
		},
		containsPoint: function(t) {
			return !(t.x < this.min.x || t.x > this.max.x || t.y < this.min.y || t.y > this.max.y)
		},
		containsBox: function(t) {
			return this.min.x <= t.min.x && t.max.x <= this.max.x && this.min.y <= t.min.y && t.max.y <= this.max.y
		},
		getParameter: function(t, e) {
			return(e || new n).set((t.x - this.min.x) / (this.max.x - this.min.x), (t.y - this.min.y) / (this.max.y - this.min.y))
		},
		intersectsBox: function(t) {
			return !(t.max.x < this.min.x || t.min.x > this.max.x || t.max.y < this.min.y || t.min.y > this.max.y)
		},
		clampPoint: function(t, e) {
			return(e || new n).copy(t).clamp(this.min, this.max)
		},
		distanceToPoint: function() {
			var t = new n;
			return function(e) {
				return t.copy(e).clamp(this.min, this.max).sub(e).length()
			}
		}(),
		intersect: function(t) {
			return this.min.max(t.min), this.max.min(t.max), this
		},
		union: function(t) {
			return this.min.min(t.min), this.max.max(t.max), this
		},
		translate: function(t) {
			return this.min.add(t), this.max.add(t), this
		},
		equals: function(t) {
			return t.min.equals(this.min) && t.max.equals(this.max)
		}
	}), J.prototype = Object.create(s.prototype), J.prototype.constructor = J;
	var qa = 0;
	Object.assign(Q.prototype, e.prototype, {
		isMaterial: !0,
		onBeforeCompile: function() {},
		setValues: function(t) {
			if(void 0 !== t)
				for(var e in t) {
					var n = t[e];
					if(void 0 !== n)
						if("shading" !== e) {
							var i = this[e];
							void 0 !== i && (i && i.isColor ? i.set(n) : i && i.isVector3 && n && n.isVector3 ? i.copy(n) : this[e] = "overdraw" === e ? Number(n) : n)
						} else this.flatShading = 1 === n
				}
		},
		toJSON: function(t) {
			function e(t) {
				var e = [];
				for(var n in t) {
					var i = t[n];
					delete i.metadata, e.push(i)
				}
				return e
			}
			var n = void 0 === t || "string" == typeof t;
			n && (t = {
				textures: {},
				images: {}
			});
			var i = {
				metadata: {
					version: 4.5,
					type: "Material",
					generator: "Material.toJSON"
				}
			};
			if(i.uuid = this.uuid, i.type = this.type, "" !== this.name && (i.name = this.name), this.color && this.color.isColor && (i.color = this.color.getHex()), void 0 !== this.roughness && (i.roughness = this.roughness), void 0 !== this.metalness && (i.metalness = this.metalness), this.emissive && this.emissive.isColor && (i.emissive = this.emissive.getHex()), 1 !== this.emissiveIntensity && (i.emissiveIntensity = this.emissiveIntensity), this.specular && this.specular.isColor && (i.specular = this.specular.getHex()), void 0 !== this.shininess && (i.shininess = this.shininess), void 0 !== this.clearCoat && (i.clearCoat = this.clearCoat), void 0 !== this.clearCoatRoughness && (i.clearCoatRoughness = this.clearCoatRoughness), this.map && this.map.isTexture && (i.map = this.map.toJSON(t).uuid), this.alphaMap && this.alphaMap.isTexture && (i.alphaMap = this.alphaMap.toJSON(t).uuid), this.lightMap && this.lightMap.isTexture && (i.lightMap = this.lightMap.toJSON(t).uuid), this.bumpMap && this.bumpMap.isTexture && (i.bumpMap = this.bumpMap.toJSON(t).uuid, i.bumpScale = this.bumpScale), this.normalMap && this.normalMap.isTexture && (i.normalMap = this.normalMap.toJSON(t).uuid, i.normalScale = this.normalScale.toArray()), this.displacementMap && this.displacementMap.isTexture && (i.displacementMap = this.displacementMap.toJSON(t).uuid, i.displacementScale = this.displacementScale, i.displacementBias = this.displacementBias), this.roughnessMap && this.roughnessMap.isTexture && (i.roughnessMap = this.roughnessMap.toJSON(t).uuid), this.metalnessMap && this.metalnessMap.isTexture && (i.metalnessMap = this.metalnessMap.toJSON(t).uuid), this.emissiveMap && this.emissiveMap.isTexture && (i.emissiveMap = this.emissiveMap.toJSON(t).uuid), this.specularMap && this.specularMap.isTexture && (i.specularMap = this.specularMap.toJSON(t).uuid), this.envMap && this.envMap.isTexture && (i.envMap = this.envMap.toJSON(t).uuid, i.reflectivity = this.reflectivity), this.gradientMap && this.gradientMap.isTexture && (i.gradientMap = this.gradientMap.toJSON(t).uuid), void 0 !== this.size && (i.size = this.size), void 0 !== this.sizeAttenuation && (i.sizeAttenuation = this.sizeAttenuation), this.blending !== qi && (i.blending = this.blending), !0 === this.flatShading && (i.flatShading = this.flatShading), this.side !== Vi && (i.side = this.side), this.vertexColors !== Wi && (i.vertexColors = this.vertexColors), this.opacity < 1 && (i.opacity = this.opacity), !0 === this.transparent && (i.transparent = this.transparent), i.depthFunc = this.depthFunc, i.depthTest = this.depthTest, i.depthWrite = this.depthWrite, 0 !== this.rotation && (i.rotation = this.rotation), 1 !== this.linewidth && (i.linewidth = this.linewidth), void 0 !== this.dashSize && (i.dashSize = this.dashSize), void 0 !== this.gapSize && (i.gapSize = this.gapSize), void 0 !== this.scale && (i.scale = this.scale), !0 === this.dithering && (i.dithering = !0), this.alphaTest > 0 && (i.alphaTest = this.alphaTest), !0 === this.premultipliedAlpha && (i.premultipliedAlpha = this.premultipliedAlpha), !0 === this.wireframe && (i.wireframe = this.wireframe), this.wireframeLinewidth > 1 && (i.wireframeLinewidth = this.wireframeLinewidth), "round" !== this.wireframeLinecap && (i.wireframeLinecap = this.wireframeLinecap), "round" !== this.wireframeLinejoin && (i.wireframeLinejoin = this.wireframeLinejoin), !0 === this.morphTargets && (i.morphTargets = !0), !0 === this.skinning && (i.skinning = !0), !1 === this.visible && (i.visible = !1), "{}" !== JSON.stringify(this.userData) && (i.userData = this.userData), n) {
				var r = e(t.textures),
					a = e(t.images);
				r.length > 0 && (i.textures = r), a.length > 0 && (i.images = a)
			}
			return i
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			this.name = t.name, this.fog = t.fog, this.lights = t.lights, this.blending = t.blending, this.side = t.side, this.flatShading = t.flatShading, this.vertexColors = t.vertexColors, this.opacity = t.opacity, this.transparent = t.transparent, this.blendSrc = t.blendSrc, this.blendDst = t.blendDst, this.blendEquation = t.blendEquation, this.blendSrcAlpha = t.blendSrcAlpha, this.blendDstAlpha = t.blendDstAlpha, this.blendEquationAlpha = t.blendEquationAlpha, this.depthFunc = t.depthFunc, this.depthTest = t.depthTest, this.depthWrite = t.depthWrite, this.colorWrite = t.colorWrite, this.precision = t.precision, this.polygonOffset = t.polygonOffset, this.polygonOffsetFactor = t.polygonOffsetFactor, this.polygonOffsetUnits = t.polygonOffsetUnits, this.dithering = t.dithering, this.alphaTest = t.alphaTest, this.premultipliedAlpha = t.premultipliedAlpha, this.overdraw = t.overdraw, this.visible = t.visible, this.userData = JSON.parse(JSON.stringify(t.userData)), this.clipShadows = t.clipShadows, this.clipIntersection = t.clipIntersection;
			var e = t.cs,
				n = null;
			if(null !== e) {
				var i = e.length;
				n = new Array(i);
				for(var r = 0; r !== i; ++r) n[r] = e[r].clone()
			}
			return this.cs = n, this
		},
		dispose: function() {
			this.dispatchEvent({
				type: "dispose"
			})
		}
	}), $.prototype = Object.create(Q.prototype), $.prototype.constructor = $, $.prototype.isMeshDepthMaterial = !0, $.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.depthPacking = t.depthPacking, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.map = t.map, this.alphaMap = t.alphaMap, this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this
	}, tt.prototype = Object.create(Q.prototype), tt.prototype.constructor = tt, tt.prototype.isMeshDistanceMaterial = !0, tt.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.referencePosition.copy(t.referencePosition), this.nearDistance = t.nearDistance, this.farDistance = t.farDistance, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.map = t.map, this.alphaMap = t.alphaMap, this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this
	}, Object.assign(et.prototype, {
		isBox3: !0,
		set: function(t, e) {
			return this.min.copy(t), this.max.copy(e), this
		},
		setFromArray: function(t) {
			for(var e = 1 / 0, n = 1 / 0, i = 1 / 0, r = -1 / 0, a = -1 / 0, o = -1 / 0, s = 0, l = t.length; s < l; s += 3) {
				var c = t[s],
					h = t[s + 1],
					u = t[s + 2];
				c < e && (e = c), h < n && (n = h), u < i && (i = u), c > r && (r = c), h > a && (a = h), u > o && (o = u)
			}
			return this.min.set(e, n, i), this.max.set(r, a, o), this
		},
		setFromBufferAttribute: function(t) {
			for(var e = 1 / 0, n = 1 / 0, i = 1 / 0, r = -1 / 0, a = -1 / 0, o = -1 / 0, s = 0, l = t.count; s < l; s++) {
				var c = t.getX(s),
					h = t.getY(s),
					u = t.getZ(s);
				c < e && (e = c), h < n && (n = h), u < i && (i = u), c > r && (r = c), h > a && (a = h), u > o && (o = u)
			}
			return this.min.set(e, n, i), this.max.set(r, a, o), this
		},
		setFromPoints: function(t) {
			this.makeEmpty();
			for(var e = 0, n = t.length; e < n; e++) this.expandByPoint(t[e]);
			return this
		},
		setFromCenterAndSize: function() {
			var t = new a;
			return function(e, n) {
				var i = t.copy(n).multiplyScalar(.5);
				return this.min.copy(e).sub(i), this.max.copy(e).add(i), this
			}
		}(),
		st: function(t) {
			return this.makeEmpty(), this.expandByObject(t)
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.min.copy(t.min), this.max.copy(t.max), this
		},
		makeEmpty: function() {
			return this.min.x = this.min.y = this.min.z = 1 / 0, this.max.x = this.max.y = this.max.z = -1 / 0, this
		},
		isEmpty: function() {
			return this.max.x < this.min.x || this.max.y < this.min.y || this.max.z < this.min.z
		},
		getCenter: function(t) {
			var e = t || new a;
			return this.isEmpty() ? e.set(0, 0, 0) : e.addVectors(this.min, this.max).multiplyScalar(.5)
		},
		getSize: function(t) {
			var e = t || new a;
			return this.isEmpty() ? e.set(0, 0, 0) : e.subVectors(this.max, this.min)
		},
		expandByPoint: function(t) {
			return this.min.min(t), this.max.max(t), this
		},
		expandByVector: function(t) {
			return this.min.sub(t), this.max.add(t), this
		},
		expandByScalar: function(t) {
			return this.min.addScalar(-t), this.max.addScalar(t), this
		},
		expandByObject: function() {
			function t(t) {
				var a = t.geometry;
				if(void 0 !== a)
					if(a.isGeometry) {
						var o = a.vertices;
						for(n = 0, i = o.length; n < i; n++) r.copy(o[n]), r.applyMatrix4(t.matrixWorld), e.expandByPoint(r)
					} else if(a.isBufferGeometry) {
					var s = a.attributes.position;
					if(void 0 !== s)
						for(n = 0, i = s.count; n < i; n++) r.fromBufferAttribute(s, n).applyMatrix4(t.matrixWorld), e.expandByPoint(r)
				}
			}
			var e, n, i, r = new a;
			return function(n) {
				return e = this, n.uld(!0), n.traverse(t), this
			}
		}(),
		containsPoint: function(t) {
			return !(t.x < this.min.x || t.x > this.max.x || t.y < this.min.y || t.y > this.max.y || t.z < this.min.z || t.z > this.max.z)
		},
		containsBox: function(t) {
			return this.min.x <= t.min.x && t.max.x <= this.max.x && this.min.y <= t.min.y && t.max.y <= this.max.y && this.min.z <= t.min.z && t.max.z <= this.max.z
		},
		getParameter: function(t, e) {
			return(e || new a).set((t.x - this.min.x) / (this.max.x - this.min.x), (t.y - this.min.y) / (this.max.y - this.min.y), (t.z - this.min.z) / (this.max.z - this.min.z))
		},
		intersectsBox: function(t) {
			return !(t.max.x < this.min.x || t.min.x > this.max.x || t.max.y < this.min.y || t.min.y > this.max.y || t.max.z < this.min.z || t.min.z > this.max.z)
		},
		intersectsSphere: function() {
			var t = new a;
			return function(e) {
				return this.clampPoint(e.center, t), t.distanceToSquared(e.center) <= e.radius * e.radius
			}
		}(),
		intersectsPlane: function(t) {
			var e, n;
			return t.normal.x > 0 ? (e = t.normal.x * this.min.x, n = t.normal.x * this.max.x) : (e = t.normal.x * this.max.x, n = t.normal.x * this.min.x), t.normal.y > 0 ? (e += t.normal.y * this.min.y, n += t.normal.y * this.max.y) : (e += t.normal.y * this.max.y, n += t.normal.y * this.min.y), t.normal.z > 0 ? (e += t.normal.z * this.min.z, n += t.normal.z * this.max.z) : (e += t.normal.z * this.max.z, n += t.normal.z * this.min.z), e <= t.constant && n >= t.constant
		},
		clampPoint: function(t, e) {
			return(e || new a).copy(t).clamp(this.min, this.max)
		},
		distanceToPoint: function() {
			var t = new a;
			return function(e) {
				return t.copy(e).clamp(this.min, this.max).sub(e).length()
			}
		}(),
		getBoundingSphere: function() {
			var t = new a;
			return function(e) {
				var n = e || new nt;
				return this.getCenter(n.center), n.radius = .5 * this.getSize(t).length(), n
			}
		}(),
		intersect: function(t) {
			return this.min.max(t.min), this.max.min(t.max), this.isEmpty() && this.makeEmpty(), this
		},
		union: function(t) {
			return this.min.min(t.min), this.max.max(t.max), this
		},
		applyMatrix4: function() {
			var t = [new a, new a, new a, new a, new a, new a, new a, new a];
			return function(e) {
				return this.isEmpty() ? this : (t[0].set(this.min.x, this.min.y, this.min.z).applyMatrix4(e), t[1].set(this.min.x, this.min.y, this.max.z).applyMatrix4(e), t[2].set(this.min.x, this.max.y, this.min.z).applyMatrix4(e), t[3].set(this.min.x, this.max.y, this.max.z).applyMatrix4(e), t[4].set(this.max.x, this.min.y, this.min.z).applyMatrix4(e), t[5].set(this.max.x, this.min.y, this.max.z).applyMatrix4(e), t[6].set(this.max.x, this.max.y, this.min.z).applyMatrix4(e), t[7].set(this.max.x, this.max.y, this.max.z).applyMatrix4(e), this.setFromPoints(t), this)
			}
		}(),
		translate: function(t) {
			return this.min.add(t), this.max.add(t), this
		},
		equals: function(t) {
			return t.min.equals(this.min) && t.max.equals(this.max)
		}
	}), Object.assign(nt.prototype, {
		set: function(t, e) {
			return this.center.copy(t), this.radius = e, this
		},
		setFromPoints: function() {
			var t = new et;
			return function(e, n) {
				var i = this.center;
				void 0 !== n ? i.copy(n) : t.setFromPoints(e).getCenter(i);
				for(var r = 0, a = 0, o = e.length; a < o; a++) r = Math.max(r, i.distanceToSquared(e[a]));
				return this.radius = Math.sqrt(r), this
			}
		}(),
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.center.copy(t.center), this.radius = t.radius, this
		},
		empty: function() {
			return this.radius <= 0
		},
		containsPoint: function(t) {
			return t.distanceToSquared(this.center) <= this.radius * this.radius
		},
		distanceToPoint: function(t) {
			return t.distanceTo(this.center) - this.radius
		},
		intersectsSphere: function(t) {
			var e = this.radius + t.radius;
			return t.center.distanceToSquared(this.center) <= e * e
		},
		intersectsBox: function(t) {
			return t.intersectsSphere(this)
		},
		intersectsPlane: function(t) {
			return Math.abs(t.distanceToPoint(this.center)) <= this.radius
		},
		clampPoint: function(t, e) {
			var n = this.center.distanceToSquared(t),
				i = e || new a;
			return i.copy(t), n > this.radius * this.radius && (i.sub(this.center).normalize(), i.multiplyScalar(this.radius).add(this.center)), i
		},
		getBoundingBox: function(t) {
			var e = t || new et;
			return e.set(this.center, this.center), e.expandByScalar(this.radius), e
		},
		applyMatrix4: function(t) {
			return this.center.applyMatrix4(t), this.radius = this.radius * t.getMaxScaleOnAxis(), this
		},
		translate: function(t) {
			return this.center.add(t), this
		},
		equals: function(t) {
			return t.center.equals(this.center) && t.radius === this.radius
		}
	}), Object.assign(it.prototype, {
		set: function(t, e) {
			return this.normal.copy(t), this.constant = e, this
		},
		setComponents: function(t, e, n, i) {
			return this.normal.set(t, e, n), this.constant = i, this
		},
		setFromNormalAndCoplanarPoint: function(t, e) {
			return this.normal.copy(t), this.constant = -e.dot(this.normal), this
		},
		setFromCoplanarPoints: function() {
			var t = new a,
				e = new a;
			return function(n, i, r) {
				var a = t.subVectors(r, i).cross(e.subVectors(n, i)).normalize();
				return this.setFromNormalAndCoplanarPoint(a, n), this
			}
		}(),
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.normal.copy(t.normal), this.constant = t.constant, this
		},
		normalize: function() {
			var t = 1 / this.normal.length();
			return this.normal.multiplyScalar(t), this.constant *= t, this
		},
		negate: function() {
			return this.constant *= -1, this.normal.negate(), this
		},
		distanceToPoint: function(t) {
			return this.normal.dot(t) + this.constant
		},
		distanceToSphere: function(t) {
			return this.distanceToPoint(t.center) - t.radius
		},
		projectPoint: function(t, e) {
			return(e || new a).copy(this.normal).multiplyScalar(-this.distanceToPoint(t)).add(t)
		},
		intersectLine: function() {
			var t = new a;
			return function(e, n) {
				var i = n || new a,
					r = e.delta(t),
					o = this.normal.dot(r);
				if(0 !== o) {
					var s = -(e.start.dot(this.normal) + this.constant) / o;
					if(!(s < 0 || s > 1)) return i.copy(r).multiplyScalar(s).add(e.start)
				} else if(0 === this.distanceToPoint(e.start)) return i.copy(e.start)
			}
		}(),
		intersectsLine: function(t) {
			var e = this.distanceToPoint(t.start),
				n = this.distanceToPoint(t.end);
			return e < 0 && n > 0 || n < 0 && e > 0
		},
		intersectsBox: function(t) {
			return t.intersectsPlane(this)
		},
		intersectsSphere: function(t) {
			return t.intersectsPlane(this)
		},
		coplanarPoint: function(t) {
			return(t || new a).copy(this.normal).multiplyScalar(-this.constant)
		},
		applyMatrix4: function() {
			var t = new a,
				e = new o;
			return function(n, i) {
				var r = i || e.getNormalMatrix(n),
					a = this.coplanarPoint(t).applyMatrix4(n),
					o = this.normal.applyMatrix3(r).normalize();
				return this.constant = -a.dot(o), this
			}
		}(),
		translate: function(t) {
			return this.constant -= t.dot(this.normal), this
		},
		equals: function(t) {
			return t.normal.equals(this.normal) && t.constant === this.constant
		}
	}), Object.assign(rt.prototype, {
		set: function(t, e, n, i, r, a) {
			var o = this.planes;
			return o[0].copy(t), o[1].copy(e), o[2].copy(n), o[3].copy(i), o[4].copy(r), o[5].copy(a), this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			for(var e = this.planes, n = 0; n < 6; n++) e[n].copy(t.planes[n]);
			return this
		},
		setFromMatrix: function(t) {
			var e = this.planes,
				n = t.elements,
				i = n[0],
				r = n[1],
				a = n[2],
				o = n[3],
				s = n[4],
				l = n[5],
				c = n[6],
				h = n[7],
				u = n[8],
				f = n[9],
				p = n[10],
				d = n[11],
				m = n[12],
				g = n[13],
				v = n[14],
				_ = n[15];
			return e[0].setComponents(o - i, h - s, d - u, _ - m).normalize(), e[1].setComponents(o + i, h + s, d + u, _ + m).normalize(), e[2].setComponents(o + r, h + l, d + f, _ + g).normalize(), e[3].setComponents(o - r, h - l, d - f, _ - g).normalize(), e[4].setComponents(o - a, h - c, d - p, _ - v).normalize(), e[5].setComponents(o + a, h + c, d + p, _ + v).normalize(), this
		},
		intersectsObject: function() {
			var t = new nt;
			return function(e) {
				var n = e.geometry;
				return null === n.boundingSphere && n.computeBoundingSphere(), t.copy(n.boundingSphere).applyMatrix4(e.matrixWorld), this.intersectsSphere(t)
			}
		}(),
		intersectsSprite: function() {
			var t = new nt;
			return function(e) {
				return t.center.set(0, 0, 0), t.radius = .7071067811865476, t.applyMatrix4(e.matrixWorld), this.intersectsSphere(t)
			}
		}(),
		intersectsSphere: function(t) {
			for(var e = this.planes, n = t.center, i = -t.radius, r = 0; r < 6; r++)
				if(e[r].distanceToPoint(n) < i) return !1;
			return !0
		},
		intersectsBox: function() {
			var t = new a,
				e = new a;
			return function(n) {
				for(var i = this.planes, r = 0; r < 6; r++) {
					var a = i[r];
					t.x = a.normal.x > 0 ? n.min.x : n.max.x, e.x = a.normal.x > 0 ? n.max.x : n.min.x, t.y = a.normal.y > 0 ? n.min.y : n.max.y, e.y = a.normal.y > 0 ? n.max.y : n.min.y, t.z = a.normal.z > 0 ? n.min.z : n.max.z, e.z = a.normal.z > 0 ? n.max.z : n.min.z;
					var o = a.distanceToPoint(t),
						s = a.distanceToPoint(e);
					if(o < 0 && s < 0) return !1
				}
				return !0
			}
		}(),
		containsPoint: function(t) {
			for(var e = this.planes, n = 0; n < 6; n++)
				if(e[n].distanceToPoint(t) < 0) return !1;
			return !0
		}
	}), st.RotationOrders = ["XYZ", "YZX", "ZXY", "XZY", "YXZ", "ZYX"], st.DefaultOrder = "XYZ", Object.defineProperties(st.prototype, {
		x: {
			get: function() {
				return this._x
			},
			set: function(t) {
				this._x = t, this.onChangeCallback()
			}
		},
		y: {
			get: function() {
				return this._y
			},
			set: function(t) {
				this._y = t, this.onChangeCallback()
			}
		},
		z: {
			get: function() {
				return this._z
			},
			set: function(t) {
				this._z = t, this.onChangeCallback()
			}
		},
		order: {
			get: function() {
				return this._order
			},
			set: function(t) {
				this._order = t, this.onChangeCallback()
			}
		}
	}), Object.assign(st.prototype, {
		isEuler: !0,
		set: function(t, e, n, i) {
			return this._x = t, this._y = e, this._z = n, this._order = i || this._order, this.onChangeCallback(), this
		},
		clone: function() {
			return new this.constructor(this._x, this._y, this._z, this._order)
		},
		copy: function(t) {
			return this._x = t._x, this._y = t._y, this._z = t._z, this._order = t._order, this.onChangeCallback(), this
		},
		setFromRotationMatrix: function(t, e, n) {
			var i = Oa.clamp,
				r = t.elements,
				a = r[0],
				o = r[4],
				s = r[8],
				l = r[1],
				c = r[5],
				h = r[9],
				u = r[2],
				f = r[6],
				p = r[10];
			return e = e || this._order, "XYZ" === e ? (this._y = Math.asin(i(s, -1, 1)), Math.abs(s) < .99999 ? (this._x = Math.atan2(-h, p), this._z = Math.atan2(-o, a)) : (this._x = Math.atan2(f, c), this._z = 0)) : "YXZ" === e ? (this._x = Math.asin(-i(h, -1, 1)), Math.abs(h) < .99999 ? (this._y = Math.atan2(s, p), this._z = Math.atan2(l, c)) : (this._y = Math.atan2(-u, a), this._z = 0)) : "ZXY" === e ? (this._x = Math.asin(i(f, -1, 1)), Math.abs(f) < .99999 ? (this._y = Math.atan2(-u, p), this._z = Math.atan2(-o, c)) : (this._y = 0, this._z = Math.atan2(l, a))) : "ZYX" === e ? (this._y = Math.asin(-i(u, -1, 1)), Math.abs(u) < .99999 ? (this._x = Math.atan2(f, p), this._z = Math.atan2(l, a)) : (this._x = 0, this._z = Math.atan2(-o, c))) : "YZX" === e ? (this._z = Math.asin(i(l, -1, 1)), Math.abs(l) < .99999 ? (this._x = Math.atan2(-h, c), this._y = Math.atan2(-u, a)) : (this._x = 0, this._y = Math.atan2(s, p))) : "XZY" === e && (this._z = Math.asin(-i(o, -1, 1)), Math.abs(o) < .99999 ? (this._x = Math.atan2(f, c), this._y = Math.atan2(s, a)) : (this._x = Math.atan2(-h, p), this._y = 0)), this._order = e, !1 !== n && this.onChangeCallback(), this
		},
		setFromQuaternion: function() {
			var t = new i;
			return function(e, n, i) {
				return t.makeRotationFromQuaternion(e), this.setFromRotationMatrix(t, n, i)
			}
		}(),
		setFromVector3: function(t, e) {
			return this.set(t.x, t.y, t.z, e || this._order)
		},
		reorder: function() {
			var t = new r;
			return function(e) {
				return t.setFromEuler(this), this.setFromQuaternion(t, e)
			}
		}(),
		equals: function(t) {
			return t._x === this._x && t._y === this._y && t._z === this._z && t._order === this._order
		},
		fromArray: function(t) {
			return this._x = t[0], this._y = t[1], this._z = t[2], void 0 !== t[3] && (this._order = t[3]), this.onChangeCallback(), this
		},
		toArray: function(t, e) {
			return void 0 === t && (t = []), void 0 === e && (e = 0), t[e] = this._x, t[e + 1] = this._y, t[e + 2] = this._z, t[e + 3] = this._order, t
		},
		toVector3: function(t) {
			return t ? t.set(this._x, this._y, this._z) : new a(this._x, this._y, this._z)
		},
		onChange: function(t) {
			return this.onChangeCallback = t, this
		},
		onChangeCallback: function() {}
	}), Object.assign(lt.prototype, {
		set: function(t) {
			this.mask = 1 << t | 0
		},
		enable: function(t) {
			this.mask |= 1 << t | 0
		},
		toggle: function(t) {
			this.mask ^= 1 << t | 0
		},
		disable: function(t) {
			this.mask &= ~(1 << t | 0)
		},
		test: function(t) {
			return 0 != (this.mask & t.mask)
		}
	});
	var Za = 0;
	ct.DefaultUp = new a(0, 1, 0), ct.DefaultMatrixAutoUpdate = !0, Object.assign(ct.prototype, e.prototype, {
		isObject3D: !0,
		onBeforeRender: function() {},
		onAfterRender: function() {},
		applyMatrix: function(t) {
			this.matrix.multiplyMatrices(t, this.matrix), this.matrix.decompose(this.position, this.quaternion, this.scale)
		},
		applyQuaternion: function(t) {
			return this.quaternion.premultiply(t), this
		},
		setRotationFromAxisAngle: function(t, e) {
			this.quaternion.setFromAxisAngle(t, e)
		},
		setRotationFromEuler: function(t) {
			this.quaternion.setFromEuler(t, !0)
		},
		setRotationFromMatrix: function(t) {
			this.quaternion.setFromRotationMatrix(t)
		},
		setRotationFromQuaternion: function(t) {
			this.quaternion.copy(t)
		},
		rotateOnAxis: function() {
			var t = new r;
			return function(e, n) {
				return t.setFromAxisAngle(e, n), this.quaternion.multiply(t), this
			}
		}(),
		rotateOnWorldAxis: function() {
			var t = new r;
			return function(e, n) {
				return t.setFromAxisAngle(e, n), this.quaternion.premultiply(t), this
			}
		}(),
		rotateX: function() {
			var t = new a(1, 0, 0);
			return function(e) {
				return this.rotateOnAxis(t, e)
			}
		}(),
		rotateY: function() {
			var t = new a(0, 1, 0);
			return function(e) {
				return this.rotateOnAxis(t, e)
			}
		}(),
		rotateZ: function() {
			var t = new a(0, 0, 1);
			return function(e) {
				return this.rotateOnAxis(t, e)
			}
		}(),
		translateOnAxis: function() {
			var t = new a;
			return function(e, n) {
				return t.copy(e).applyQuaternion(this.quaternion), this.position.add(t.multiplyScalar(n)), this
			}
		}(),
		translateX: function() {
			var t = new a(1, 0, 0);
			return function(e) {
				return this.translateOnAxis(t, e)
			}
		}(),
		translateY: function() {
			var t = new a(0, 1, 0);
			return function(e) {
				return this.translateOnAxis(t, e)
			}
		}(),
		translateZ: function() {
			var t = new a(0, 0, 1);
			return function(e) {
				return this.translateOnAxis(t, e)
			}
		}(),
		localToWorld: function(t) {
			return t.applyMatrix4(this.matrixWorld)
		},
		worldToLocal: function() {
			var t = new i;
			return function(e) {
				return e.applyMatrix4(t.getInverse(this.matrixWorld))
			}
		}(),
		lookAt: function() {
			var t = new i,
				e = new a;
			return function(n, i, r) {
				n.isVector3 ? e.copy(n) : e.set(n, i, r), this.isCamera ? t.lookAt(this.position, e, this.up) : t.lookAt(e, this.position, this.up), this.quaternion.setFromRotationMatrix(t)
			}
		}(),
		add: function(t) {
			if(arguments.length > 1) {
				for(var e = 0; e < arguments.length; e++) this.add(arguments[e]);
				return this
			}
			return t === this ? this : (t && t.isObject3D && (null !== t.parent && t.parent.remove(t), t.parent = this, t.dispatchEvent({
				type: "added"
			}), this.children.push(t)), this)
		},
		remove: function(t) {
			if(arguments.length > 1) {
				for(var e = 0; e < arguments.length; e++) this.remove(arguments[e]);
				return this
			}
			var n = this.children.indexOf(t);
			return -1 !== n && (t.parent = null, t.dispatchEvent({
				type: "removed"
			}), this.children.splice(n, 1)), this
		},
		getObjectById: function(t) {
			return this.getObjectByProperty("id", t)
		},
		ge: function(t) {
			return this.getObjectByProperty("name", t)
		},
		getObjectByProperty: function(t, e) {
			if(this[t] === e) return this;
			for(var n = 0, i = this.children.length; n < i; n++) {
				var r = this.children[n].getObjectByProperty(t, e);
				if(void 0 !== r) return r
			}
		},
		getWorldPosition: function(t) {
			var e = t || new a;
			return this.uld(!0), e.setFromMatrixPosition(this.matrixWorld)
		},
		getWorldQuaternion: function() {
			var t = new a,
				e = new a;
			return function(n) {
				var i = n || new r;
				return this.uld(!0), this.matrixWorld.decompose(t, i, e), i
			}
		}(),
		getWorldRotation: function() {
			var t = new r;
			return function(e) {
				var n = e || new st;
				return this.getWorldQuaternion(t), n.setFromQuaternion(t, this.rotation.order, !1)
			}
		}(),
		getWorldScale: function() {
			var t = new a,
				e = new r;
			return function(n) {
				var i = n || new a;
				return this.uld(!0), this.matrixWorld.decompose(t, e, i), i
			}
		}(),
		getWorldDirection: function() {
			var t = new r;
			return function(e) {
				var n = e || new a;
				return this.getWorldQuaternion(t), n.set(0, 0, 1).applyQuaternion(t)
			}
		}(),
		raycast: function() {},
		traverse: function(t) {
			t(this);
			for(var e = this.children, n = 0, i = e.length; n < i; n++) e[n].traverse(t)
		},
		traverseVisible: function(t) {
			if(!1 !== this.visible) {
				t(this);
				for(var e = this.children, n = 0, i = e.length; n < i; n++) e[n].traverseVisible(t)
			}
		},
		traverseAncestors: function(t) {
			var e = this.parent;
			null !== e && (t(e), e.traverseAncestors(t))
		},
		updateMatrix: function() {
			this.matrix.compose(this.position, this.quaternion, this.scale), this.mte = !0
		},
		uld: function(t) {
			this.matrixAutoUpdate && this.updateMatrix(), (this.mte || t) && (null === this.parent ? this.matrixWorld.copy(this.matrix) : this.matrixWorld.multiplyMatrices(this.parent.matrixWorld, this.matrix), this.mte = !1, t = !0);
			for(var e = this.children, n = 0, i = e.length; n < i; n++) e[n].uld(t)
		},
		toJSON: function(t) {
			function e(e, n) {
				return void 0 === e[n.uuid] && (e[n.uuid] = n.toJSON(t)), n.uuid
			}

			function n(t) {
				var e = [];
				for(var n in t) {
					var i = t[n];
					delete i.metadata, e.push(i)
				}
				return e
			}
			var i = void 0 === t || "string" == typeof t,
				r = {};
			i && (t = {
				geometries: {},
				materials: {},
				textures: {},
				images: {}
			}, r.metadata = {
				version: 4.5,
				type: "Object",
				generator: "Object3D.toJSON"
			});
			var a = {};
			if(a.uuid = this.uuid, a.type = this.type, "" !== this.name && (a.name = this.name), !0 === this.castShadow && (a.castShadow = !0), !0 === this.receiveShadow && (a.receiveShadow = !0), !1 === this.visible && (a.visible = !1), "{}" !== JSON.stringify(this.userData) && (a.userData = this.userData), a.matrix = this.matrix.toArray(), void 0 !== this.geometry && (a.geometry = e(t.geometries, this.geometry)), void 0 !== this.material)
				if(Array.isArray(this.material)) {
					for(var o = [], s = 0, l = this.material.length; s < l; s++) o.push(e(t.materials, this.material[s]));
					a.material = o
				} else a.material = e(t.materials, this.material);
			if(this.children.length > 0) {
				a.children = [];
				for(s = 0; s < this.children.length; s++) a.children.push(this.children[s].toJSON(t).object)
			}
			if(i) {
				var c = n(t.geometries),
					h = n(t.materials),
					u = n(t.textures),
					f = n(t.images);
				c.length > 0 && (r.geometries = c), h.length > 0 && (r.materials = h), u.length > 0 && (r.textures = u), f.length > 0 && (r.images = f)
			}
			return r.object = a, r
		},
		clone: function(t) {
			return(new this.constructor).copy(this, t)
		},
		copy: function(t, e) {
			if(void 0 === e && (e = !0), this.name = t.name, this.up.copy(t.up), this.position.copy(t.position), this.quaternion.copy(t.quaternion), this.scale.copy(t.scale), this.matrix.copy(t.matrix), this.matrixWorld.copy(t.matrixWorld), this.matrixAutoUpdate = t.matrixAutoUpdate, this.mte = t.mte, this.layers.mask = t.layers.mask, this.visible = t.visible, this.castShadow = t.castShadow, this.receiveShadow = t.receiveShadow, this.frustumCulled = t.frustumCulled, this.renderOrder = t.renderOrder, this.userData = JSON.parse(JSON.stringify(t.userData)), !0 === e)
				for(var n = 0; n < t.children.length; n++) {
					var i = t.children[n];
					this.add(i.clone())
				}
			return this
		}
	}), ht.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: ht,
		isCamera: !0,
		copy: function(t, e) {
			return ct.prototype.copy.call(this, t, e), this.matrixWorldInverse.copy(t.matrixWorldInverse), this.projectionMatrix.copy(t.projectionMatrix), this
		},
		getWorldDirection: function() {
			var t = new r;
			return function(e) {
				var n = e || new a;
				return this.getWorldQuaternion(t), n.set(0, 0, -1).applyQuaternion(t)
			}
		}(),
		uld: function(t) {
			ct.prototype.uld.call(this, t), this.matrixWorldInverse.getInverse(this.matrixWorld)
		},
		clone: function() {
			return(new this.constructor).copy(this)
		}
	}), ut.prototype = Object.assign(Object.create(ht.prototype), {
		constructor: ut,
		isOrthographicCamera: !0,
		copy: function(t, e) {
			return ht.prototype.copy.call(this, t, e), this.left = t.left, this.right = t.right, this.top = t.top, this.bottom = t.bottom, this.near = t.near, this.far = t.far, this.zoom = t.zoom, this.view = null === t.view ? null : Object.assign({}, t.view), this
		},
		setViewOffset: function(t, e, n, i, r, a) {
			null === this.view && (this.view = {
				enabled: !0,
				fullWidth: 1,
				fullHeight: 1,
				offsetX: 0,
				offsetY: 0,
				width: 1,
				height: 1
			}), this.view.enabled = !0, this.view.fullWidth = t, this.view.fullHeight = e, this.view.offsetX = n, this.view.offsetY = i, this.view.width = r, this.view.height = a, this.ux()
		},
		clearViewOffset: function() {
			null !== this.view && (this.view.enabled = !1), this.ux()
		},
		ux: function() {
			var t = (this.right - this.left) / (2 * this.zoom),
				e = (this.top - this.bottom) / (2 * this.zoom),
				n = (this.right + this.left) / 2,
				i = (this.top + this.bottom) / 2,
				r = n - t,
				a = n + t,
				o = i + e,
				s = i - e;
			if(null !== this.view && this.view.enabled) {
				var l = this.zoom / (this.view.width / this.view.fullWidth),
					c = this.zoom / (this.view.height / this.view.fullHeight),
					h = (this.right - this.left) / this.view.width,
					u = (this.top - this.bottom) / this.view.height;
				a = (r += h * (this.view.offsetX / l)) + h * (this.view.width / l), s = (o -= u * (this.view.offsetY / c)) - u * (this.view.height / c)
			}
			this.projectionMatrix.makeOrthographic(r, a, o, s, this.near, this.far)
		},
		toJSON: function(t) {
			var e = ct.prototype.toJSON.call(this, t);
			return e.object.zoom = this.zoom, e.object.left = this.left, e.object.right = this.right, e.object.top = this.top, e.object.bottom = this.bottom, e.object.near = this.near, e.object.far = this.far, null !== this.view && (e.object.view = Object.assign({}, this.view)), e
		}
	}), Object.assign(ft.prototype, {
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			this.a = t.a, this.b = t.b, this.c = t.c, this.normal.copy(t.normal), this.color.copy(t.color), this.materialIndex = t.materialIndex;
			for(var e = 0, n = t.vertexNormals.length; e < n; e++) this.vertexNormals[e] = t.vertexNormals[e].clone();
			for(var e = 0, n = t.vertexColors.length; e < n; e++) this.vertexColors[e] = t.vertexColors[e].clone();
			return this
		}
	});
	var Ja = 0;
	Object.assign(pt.prototype, e.prototype, {
		isGeometry: !0,
		applyMatrix: function(t) {
			for(var e = (new o).getNormalMatrix(t), n = 0, i = this.vertices.length; n < i; n++) this.vertices[n].applyMatrix4(t);
			for(var n = 0, i = this.faces.length; n < i; n++) {
				var r = this.faces[n];
				r.normal.applyMatrix3(e).normalize();
				for(var a = 0, s = r.vertexNormals.length; a < s; a++) r.vertexNormals[a].applyMatrix3(e).normalize()
			}
			return null !== this.boundingBox && this.computeBoundingBox(), null !== this.boundingSphere && this.computeBoundingSphere(), this.verticesNeedUpdate = !0, this.normalsNeedUpdate = !0, this
		},
		rotateX: function() {
			var t = new i;
			return function(e) {
				return t.makeRotationX(e), this.applyMatrix(t), this
			}
		}(),
		rotateY: function() {
			var t = new i;
			return function(e) {
				return t.makeRotationY(e), this.applyMatrix(t), this
			}
		}(),
		rotateZ: function() {
			var t = new i;
			return function(e) {
				return t.makeRotationZ(e), this.applyMatrix(t), this
			}
		}(),
		translate: function() {
			var t = new i;
			return function(e, n, i) {
				return t.makeTranslation(e, n, i), this.applyMatrix(t), this
			}
		}(),
		scale: function() {
			var t = new i;
			return function(e, n, i) {
				return t.makeScale(e, n, i), this.applyMatrix(t), this
			}
		}(),
		lookAt: function() {
			var t = new ct;
			return function(e) {
				t.lookAt(e), t.updateMatrix(), this.applyMatrix(t.matrix)
			}
		}(),
		fromBufferGeometry: function(t) {
			function e(t, e, n, r) {
				var a = new ft(t, e, n, void 0 !== l ? [f[t].clone(), f[e].clone(), f[n].clone()] : [], void 0 !== c ? [i.colors[t].clone(), i.colors[e].clone(), i.colors[n].clone()] : [], r);
				i.faces.push(a), void 0 !== h && i.faceVertexUvs[0].push([p[t].clone(), p[e].clone(), p[n].clone()]), void 0 !== u && i.faceVertexUvs[1].push([d[t].clone(), d[e].clone(), d[n].clone()])
			}
			var i = this,
				r = null !== t.index ? t.index.array : void 0,
				o = t.attributes,
				s = o.position.array,
				l = void 0 !== o.normal ? o.normal.array : void 0,
				c = void 0 !== o.color ? o.color.array : void 0,
				h = void 0 !== o.uv ? o.uv.array : void 0,
				u = void 0 !== o.uv2 ? o.uv2.array : void 0;
			void 0 !== u && (this.faceVertexUvs[1] = []);
			for(var f = [], p = [], d = [], m = 0, g = 0; m < s.length; m += 3, g += 2) i.vertices.push(new a(s[m], s[m + 1], s[m + 2])), void 0 !== l && f.push(new a(l[m], l[m + 1], l[m + 2])), void 0 !== c && i.colors.push(new Y(c[m], c[m + 1], c[m + 2])), void 0 !== h && p.push(new n(h[g], h[g + 1])), void 0 !== u && d.push(new n(u[g], u[g + 1]));
			var v = t.groups;
			if(v.length > 0)
				for(m = 0; m < v.length; m++)
					for(var _ = v[m], y = _.start, g = y, x = y + _.count; g < x; g += 3) void 0 !== r ? e(r[g], r[g + 1], r[g + 2], _.materialIndex) : e(g, g + 1, g + 2, _.materialIndex);
			else if(void 0 !== r)
				for(m = 0; m < r.length; m += 3) e(r[m], r[m + 1], r[m + 2]);
			else
				for(m = 0; m < s.length / 3; m += 3) e(m, m + 1, m + 2);
			return this.computeFaceNormals(), null !== t.boundingBox && (this.boundingBox = t.boundingBox.clone()), null !== t.boundingSphere && (this.boundingSphere = t.boundingSphere.clone()), this
		},
		center: function() {
			this.computeBoundingBox();
			var t = this.boundingBox.getCenter().negate();
			return this.translate(t.x, t.y, t.z), t
		},
		normalize: function() {
			this.computeBoundingSphere();
			var t = this.boundingSphere.center,
				e = this.boundingSphere.radius,
				n = 0 === e ? 1 : 1 / e,
				r = new i;
			return r.set(n, 0, 0, -n * t.x, 0, n, 0, -n * t.y, 0, 0, n, -n * t.z, 0, 0, 0, 1), this.applyMatrix(r), this
		},
		computeFaceNormals: function() {
			for(var t = new a, e = new a, n = 0, i = this.faces.length; n < i; n++) {
				var r = this.faces[n],
					o = this.vertices[r.a],
					s = this.vertices[r.b],
					l = this.vertices[r.c];
				t.subVectors(l, s), e.subVectors(o, s), t.cross(e), t.normalize(), r.normal.copy(t)
			}
		},
		computeVertexNormals: function(t) {
			void 0 === t && (t = !0);
			var e, n, i, r, o, s;
			for(s = new Array(this.vertices.length), e = 0, n = this.vertices.length; e < n; e++) s[e] = new a;
			if(t) {
				var l, c, h, u = new a,
					f = new a;
				for(i = 0, r = this.faces.length; i < r; i++) o = this.faces[i], l = this.vertices[o.a], c = this.vertices[o.b], h = this.vertices[o.c], u.subVectors(h, c), f.subVectors(l, c), u.cross(f), s[o.a].add(u), s[o.b].add(u), s[o.c].add(u)
			} else
				for(this.computeFaceNormals(), i = 0, r = this.faces.length; i < r; i++) s[(o = this.faces[i]).a].add(o.normal), s[o.b].add(o.normal), s[o.c].add(o.normal);
			for(e = 0, n = this.vertices.length; e < n; e++) s[e].normalize();
			for(i = 0, r = this.faces.length; i < r; i++) {
				var p = (o = this.faces[i]).vertexNormals;
				3 === p.length ? (p[0].copy(s[o.a]), p[1].copy(s[o.b]), p[2].copy(s[o.c])) : (p[0] = s[o.a].clone(), p[1] = s[o.b].clone(), p[2] = s[o.c].clone())
			}
			this.faces.length > 0 && (this.normalsNeedUpdate = !0)
		},
		computeFlatVertexNormals: function() {
			var t, e, n;
			for(this.computeFaceNormals(), t = 0, e = this.faces.length; t < e; t++) {
				var i = (n = this.faces[t]).vertexNormals;
				3 === i.length ? (i[0].copy(n.normal), i[1].copy(n.normal), i[2].copy(n.normal)) : (i[0] = n.normal.clone(), i[1] = n.normal.clone(), i[2] = n.normal.clone())
			}
			this.faces.length > 0 && (this.normalsNeedUpdate = !0)
		},
		computeMorphNormals: function() {
			var t, e, n, i, r;
			for(n = 0, i = this.faces.length; n < i; n++)
				for((r = this.faces[n]).__originalFaceNormal ? r.__originalFaceNormal.copy(r.normal) : r.__originalFaceNormal = r.normal.clone(), r.__originalVertexNormals || (r.__originalVertexNormals = []), t = 0, e = r.vertexNormals.length; t < e; t++) r.__originalVertexNormals[t] ? r.__originalVertexNormals[t].copy(r.vertexNormals[t]) : r.__originalVertexNormals[t] = r.vertexNormals[t].clone();
			var o = new pt;
			for(o.faces = this.faces, t = 0, e = this.morphTargets.length; t < e; t++) {
				if(!this.morphNormals[t]) {
					this.morphNormals[t] = {}, this.morphNormals[t].faceNormals = [], this.morphNormals[t].vertexNormals = [];
					var s = this.morphNormals[t].faceNormals,
						l = this.morphNormals[t].vertexNormals;
					for(n = 0, i = this.faces.length; n < i; n++) h = new a, u = {
						a: new a,
						b: new a,
						c: new a
					}, s.push(h), l.push(u)
				}
				var c = this.morphNormals[t];
				o.vertices = this.morphTargets[t].vertices, o.computeFaceNormals(), o.computeVertexNormals();
				var h, u;
				for(n = 0, i = this.faces.length; n < i; n++) r = this.faces[n], h = c.faceNormals[n], u = c.vertexNormals[n], h.copy(r.normal), u.a.copy(r.vertexNormals[0]), u.b.copy(r.vertexNormals[1]), u.c.copy(r.vertexNormals[2])
			}
			for(n = 0, i = this.faces.length; n < i; n++)(r = this.faces[n]).normal = r.__originalFaceNormal, r.vertexNormals = r.__originalVertexNormals
		},
		computeLineDistances: function() {
			for(var t = 0, e = this.vertices, n = 0, i = e.length; n < i; n++) n > 0 && (t += e[n].distanceTo(e[n - 1])), this.lineDistances[n] = t
		},
		computeBoundingBox: function() {
			null === this.boundingBox && (this.boundingBox = new et), this.boundingBox.setFromPoints(this.vertices)
		},
		computeBoundingSphere: function() {
			null === this.boundingSphere && (this.boundingSphere = new nt), this.boundingSphere.setFromPoints(this.vertices)
		},
		merge: function(t, e, n) {
			if(t && t.isGeometry) {
				var i, r = this.vertices.length,
					a = this.vertices,
					s = t.vertices,
					l = this.faces,
					c = t.faces,
					h = this.faceVertexUvs[0],
					u = t.faceVertexUvs[0],
					f = this.colors,
					p = t.colors;
				void 0 === n && (n = 0), void 0 !== e && (i = (new o).getNormalMatrix(e));
				for(var d = 0, m = s.length; d < m; d++) {
					var g = s[d].clone();
					void 0 !== e && g.applyMatrix4(e), a.push(g)
				}
				for(var d = 0, m = p.length; d < m; d++) f.push(p[d].clone());
				for(d = 0, m = c.length; d < m; d++) {
					var v, _, y, x = c[d],
						b = x.vertexNormals,
						w = x.vertexColors;
					(v = new ft(x.a + r, x.b + r, x.c + r)).normal.copy(x.normal), void 0 !== i && v.normal.applyMatrix3(i).normalize();
					for(var M = 0, S = b.length; M < S; M++) _ = b[M].clone(), void 0 !== i && _.applyMatrix3(i).normalize(), v.vertexNormals.push(_);
					v.color.copy(x.color);
					for(var M = 0, S = w.length; M < S; M++) y = w[M], v.vertexColors.push(y.clone());
					v.materialIndex = x.materialIndex + n, l.push(v)
				}
				for(d = 0, m = u.length; d < m; d++) {
					var G = u[d],
						E = [];
					if(void 0 !== G) {
						for(var M = 0, S = G.length; M < S; M++) E.push(G[M].clone());
						h.push(E)
					}
				}
			}
		},
		mergeMesh: function(t) {
			t && t.isMesh && (t.matrixAutoUpdate && t.updateMatrix(), this.merge(t.geometry, t.matrix))
		},
		mergeVertices: function() {
			var t, e, n, i, r, a, o, s, l = {},
				c = [],
				h = [],
				u = Math.pow(10, 4);
			for(n = 0, i = this.vertices.length; n < i; n++) t = this.vertices[n], void 0 === l[e = Math.round(t.x * u) + "_" + Math.round(t.y * u) + "_" + Math.round(t.z * u)] ? (l[e] = n, c.push(this.vertices[n]), h[n] = c.length - 1) : h[n] = h[l[e]];
			var f = [];
			for(n = 0, i = this.faces.length; n < i; n++) {
				(r = this.faces[n]).a = h[r.a], r.b = h[r.b], r.c = h[r.c], a = [r.a, r.b, r.c];
				for(var p = 0; p < 3; p++)
					if(a[p] === a[(p + 1) % 3]) {
						f.push(n);
						break
					}
			}
			for(n = f.length - 1; n >= 0; n--) {
				var d = f[n];
				for(this.faces.splice(d, 1), o = 0, s = this.faceVertexUvs.length; o < s; o++) this.faceVertexUvs[o].splice(d, 1)
			}
			var m = this.vertices.length - c.length;
			return this.vertices = c, m
		},
		setFromPoints: function(t) {
			this.vertices = [];
			for(var e = 0, n = t.length; e < n; e++) {
				var i = t[e];
				this.vertices.push(new a(i.x, i.y, i.z || 0))
			}
			return this
		},
		sortFacesByMaterialIndex: function() {
			for(var t = this.faces, e = t.length, n = 0; n < e; n++) t[n]._id = n;
			t.sort(function(t, e) {
				return t.materialIndex - e.materialIndex
			});
			var i, r, a = this.faceVertexUvs[0],
				o = this.faceVertexUvs[1];
			a && a.length === e && (i = []), o && o.length === e && (r = []);
			for(n = 0; n < e; n++) {
				var s = t[n]._id;
				i && i.push(a[s]), r && r.push(o[s])
			}
			i && (this.faceVertexUvs[0] = i), r && (this.faceVertexUvs[1] = r)
		},
		toJSON: function() {
			function t(t, e, n) {
				return n ? t | 1 << e : t & ~(1 << e)
			}

			function e(t) {
				var e = t.x.toString() + t.y.toString() + t.z.toString();
				return void 0 !== f[e] ? f[e] : (f[e] = u.length / 3, u.push(t.x, t.y, t.z), f[e])
			}

			function n(t) {
				var e = t.r.toString() + t.g.toString() + t.b.toString();
				return void 0 !== d[e] ? d[e] : (d[e] = p.length, p.push(t.getHex()), d[e])
			}

			function i(t) {
				var e = t.x.toString() + t.y.toString();
				return void 0 !== g[e] ? g[e] : (g[e] = m.length / 2, m.push(t.x, t.y), g[e])
			}
			var r = {
				metadata: {
					version: 4.5,
					type: "Geometry",
					generator: "Geometry.toJSON"
				}
			};
			if(r.uuid = this.uuid, r.type = this.type, "" !== this.name && (r.name = this.name), void 0 !== this.parameters) {
				var a = this.parameters;
				for(var o in a) void 0 !== a[o] && (r[o] = a[o]);
				return r
			}
			for(var s = [], l = 0; l < this.vertices.length; l++) {
				var c = this.vertices[l];
				s.push(c.x, c.y, c.z)
			}
			for(var h = [], u = [], f = {}, p = [], d = {}, m = [], g = {}, l = 0; l < this.faces.length; l++) {
				var v = this.faces[l],
					_ = void 0 !== this.faceVertexUvs[0][l],
					y = v.normal.length() > 0,
					x = v.vertexNormals.length > 0,
					b = 1 !== v.color.r || 1 !== v.color.g || 1 !== v.color.b,
					w = v.vertexColors.length > 0,
					M = 0;
				if(M = t(M, 0, 0), M = t(M, 1, !0), M = t(M, 2, !1), M = t(M, 3, _), M = t(M, 4, y), M = t(M, 5, x), M = t(M, 6, b), M = t(M, 7, w), h.push(M), h.push(v.a, v.b, v.c), h.push(v.materialIndex), _) {
					var S = this.faceVertexUvs[0][l];
					h.push(i(S[0]), i(S[1]), i(S[2]))
				}
				if(y && h.push(e(v.normal)), x) {
					var G = v.vertexNormals;
					h.push(e(G[0]), e(G[1]), e(G[2]))
				}
				if(b && h.push(n(v.color)), w) {
					var E = v.vertexColors;
					h.push(n(E[0]), n(E[1]), n(E[2]))
				}
			}
			return r.data = {}, r.data.vertices = s, r.data.normals = u, p.length > 0 && (r.data.colors = p), m.length > 0 && (r.data.uvs = [m]), r.data.faces = h, r
		},
		clone: function() {
			return(new pt).copy(this)
		},
		copy: function(t) {
			var e, n, i, r, a, o;
			this.vertices = [], this.colors = [], this.faces = [], this.faceVertexUvs = [
				[]
			], this.morphTargets = [], this.morphNormals = [], this.skinWeights = [], this.skinIndices = [], this.lineDistances = [], this.boundingBox = null, this.boundingSphere = null, this.name = t.name;
			var s = t.vertices;
			for(e = 0, n = s.length; e < n; e++) this.vertices.push(s[e].clone());
			var l = t.colors;
			for(e = 0, n = l.length; e < n; e++) this.colors.push(l[e].clone());
			var c = t.faces;
			for(e = 0, n = c.length; e < n; e++) this.faces.push(c[e].clone());
			for(e = 0, n = t.faceVertexUvs.length; e < n; e++) {
				var h = t.faceVertexUvs[e];
				for(void 0 === this.faceVertexUvs[e] && (this.faceVertexUvs[e] = []), i = 0, r = h.length; i < r; i++) {
					var u = h[i],
						f = [];
					for(a = 0, o = u.length; a < o; a++) {
						var p = u[a];
						f.push(p.clone())
					}
					this.faceVertexUvs[e].push(f)
				}
			}
			var d = t.morphTargets;
			for(e = 0, n = d.length; e < n; e++) {
				var m = {};
				if(m.name = d[e].name, void 0 !== d[e].vertices)
					for(m.vertices = [], i = 0, r = d[e].vertices.length; i < r; i++) m.vertices.push(d[e].vertices[i].clone());
				if(void 0 !== d[e].normals)
					for(m.normals = [], i = 0, r = d[e].normals.length; i < r; i++) m.normals.push(d[e].normals[i].clone());
				this.morphTargets.push(m)
			}
			var g = t.morphNormals;
			for(e = 0, n = g.length; e < n; e++) {
				var v = {};
				if(void 0 !== g[e].vertexNormals)
					for(v.vertexNormals = [], i = 0, r = g[e].vertexNormals.length; i < r; i++) {
						var _ = g[e].vertexNormals[i],
							y = {};
						y.a = _.a.clone(), y.b = _.b.clone(), y.c = _.c.clone(), v.vertexNormals.push(y)
					}
				if(void 0 !== g[e].faceNormals)
					for(v.faceNormals = [], i = 0, r = g[e].faceNormals.length; i < r; i++) v.faceNormals.push(g[e].faceNormals[i].clone());
				this.morphNormals.push(v)
			}
			var x = t.skinWeights;
			for(e = 0, n = x.length; e < n; e++) this.skinWeights.push(x[e].clone());
			var b = t.skinIndices;
			for(e = 0, n = b.length; e < n; e++) this.skinIndices.push(b[e].clone());
			var w = t.lineDistances;
			for(e = 0, n = w.length; e < n; e++) this.lineDistances.push(w[e]);
			var M = t.boundingBox;
			null !== M && (this.boundingBox = M.clone());
			var S = t.boundingSphere;
			return null !== S && (this.boundingSphere = S.clone()), this.elementsNeedUpdate = t.elementsNeedUpdate, this.verticesNeedUpdate = t.verticesNeedUpdate, this.uvsNeedUpdate = t.uvsNeedUpdate, this.normalsNeedUpdate = t.normalsNeedUpdate, this.colorsNeedUpdate = t.colorsNeedUpdate, this.lineDistancesNeedUpdate = t.lineDistancesNeedUpdate, this.groupsNeedUpdate = t.groupsNeedUpdate, this
		},
		dispose: function() {
			this.dispatchEvent({
				type: "dispose"
			})
		}
	}), Object.defineProperty(dt.prototype, "needsUpdate", {
		set: function(t) {
			!0 === t && this.version++
		}
	}), Object.assign(dt.prototype, {
		isBufferAttribute: !0,
		setArray: function(t) {
			this.count = void 0 !== t ? t.length / this.itemSize : 0, this.array = t
		},
		setDynamic: function(t) {
			return this.dynamic = t, this
		},
		copy: function(t) {
			return this.array = new t.array.constructor(t.array), this.itemSize = t.itemSize, this.count = t.count, this.normalized = t.normalized, this.dynamic = t.dynamic, this
		},
		copyAt: function(t, e, n) {
			t *= this.itemSize, n *= e.itemSize;
			for(var i = 0, r = this.itemSize; i < r; i++) this.array[t + i] = e.array[n + i];
			return this
		},
		copyArray: function(t) {
			return this.array.set(t), this
		},
		copyColorsArray: function(t) {
			for(var e = this.array, n = 0, i = 0, r = t.length; i < r; i++) {
				var a = t[i];
				void 0 === a && (a = new Y), e[n++] = a.r, e[n++] = a.g, e[n++] = a.b
			}
			return this
		},
		copyIndicesArray: function(t) {
			for(var e = this.array, n = 0, i = 0, r = t.length; i < r; i++) {
				var a = t[i];
				e[n++] = a.a, e[n++] = a.b, e[n++] = a.c
			}
			return this
		},
		copyVector2sArray: function(t) {
			for(var e = this.array, i = 0, r = 0, a = t.length; r < a; r++) {
				var o = t[r];
				void 0 === o && (o = new n), e[i++] = o.x, e[i++] = o.y
			}
			return this
		},
		copyVector3sArray: function(t) {
			for(var e = this.array, n = 0, i = 0, r = t.length; i < r; i++) {
				var o = t[i];
				void 0 === o && (o = new a), e[n++] = o.x, e[n++] = o.y, e[n++] = o.z
			}
			return this
		},
		copyVector4sArray: function(t) {
			for(var e = this.array, n = 0, i = 0, r = t.length; i < r; i++) {
				var a = t[i];
				void 0 === a && (a = new l), e[n++] = a.x, e[n++] = a.y, e[n++] = a.z, e[n++] = a.w
			}
			return this
		},
		set: function(t, e) {
			return void 0 === e && (e = 0), this.array.set(t, e), this
		},
		getX: function(t) {
			return this.array[t * this.itemSize]
		},
		setX: function(t, e) {
			return this.array[t * this.itemSize] = e, this
		},
		getY: function(t) {
			return this.array[t * this.itemSize + 1]
		},
		setY: function(t, e) {
			return this.array[t * this.itemSize + 1] = e, this
		},
		getZ: function(t) {
			return this.array[t * this.itemSize + 2]
		},
		setZ: function(t, e) {
			return this.array[t * this.itemSize + 2] = e, this
		},
		getW: function(t) {
			return this.array[t * this.itemSize + 3]
		},
		setW: function(t, e) {
			return this.array[t * this.itemSize + 3] = e, this
		},
		setXY: function(t, e, n) {
			return t *= this.itemSize, this.array[t + 0] = e, this.array[t + 1] = n, this
		},
		setXYZ: function(t, e, n, i) {
			return t *= this.itemSize, this.array[t + 0] = e, this.array[t + 1] = n, this.array[t + 2] = i, this
		},
		setXYZW: function(t, e, n, i, r) {
			return t *= this.itemSize, this.array[t + 0] = e, this.array[t + 1] = n, this.array[t + 2] = i, this.array[t + 3] = r, this
		},
		onUpload: function(t) {
			return this.onUploadCallback = t, this
		},
		clone: function() {
			return new this.constructor(this.array, this.itemSize).copy(this)
		}
	}), mt.prototype = Object.create(dt.prototype), mt.prototype.constructor = mt, gt.prototype = Object.create(dt.prototype), gt.prototype.constructor = gt, vt.prototype = Object.create(dt.prototype), vt.prototype.constructor = vt, _t.prototype = Object.create(dt.prototype), _t.prototype.constructor = _t, yt.prototype = Object.create(dt.prototype), yt.prototype.constructor = yt, xt.prototype = Object.create(dt.prototype), xt.prototype.constructor = xt, bt.prototype = Object.create(dt.prototype), bt.prototype.constructor = bt, wt.prototype = Object.create(dt.prototype), wt.prototype.constructor = wt, Mt.prototype = Object.create(dt.prototype), Mt.prototype.constructor = Mt, Object.assign(St.prototype, {
		computeGroups: function(t) {
			for(var e, n = [], i = void 0, r = t.faces, a = 0; a < r.length; a++) {
				var o = r[a];
				o.materialIndex !== i && (i = o.materialIndex, void 0 !== e && (e.count = 3 * a - e.start, n.push(e)), e = {
					start: 3 * a,
					materialIndex: i
				})
			}
			void 0 !== e && (e.count = 3 * a - e.start, n.push(e)), this.groups = n
		},
		fromGeometry: function(t) {
			var e, i = t.faces,
				r = t.vertices,
				a = t.faceVertexUvs,
				o = a[0] && a[0].length > 0,
				s = a[1] && a[1].length > 0,
				l = t.morphTargets,
				c = l.length;
			if(c > 0) {
				e = [];
				for(v = 0; v < c; v++) e[v] = [];
				this.morphTargets.position = e
			}
			var h, u = t.morphNormals,
				f = u.length;
			if(f > 0) {
				h = [];
				for(v = 0; v < f; v++) h[v] = [];
				this.morphTargets.normal = h
			}
			for(var p = t.skinIndices, d = t.skinWeights, m = p.length === r.length, g = d.length === r.length, v = 0; v < i.length; v++) {
				var _ = i[v];
				this.vertices.push(r[_.a], r[_.b], r[_.c]);
				var y = _.vertexNormals;
				if(3 === y.length) this.normals.push(y[0], y[1], y[2]);
				else {
					var x = _.normal;
					this.normals.push(x, x, x)
				}
				var b = _.vertexColors;
				if(3 === b.length) this.colors.push(b[0], b[1], b[2]);
				else {
					var w = _.color;
					this.colors.push(w, w, w)
				}
				if(!0 === o && (void 0 !== (M = a[0][v]) ? this.uvs.push(M[0], M[1], M[2]) : this.uvs.push(new n, new n, new n)), !0 === s) {
					var M = a[1][v];
					void 0 !== M ? this.uvs2.push(M[0], M[1], M[2]) : this.uvs2.push(new n, new n, new n)
				}
				for(G = 0; G < c; G++) {
					var S = l[G].vertices;
					e[G].push(S[_.a], S[_.b], S[_.c])
				}
				for(var G = 0; G < f; G++) {
					var E = u[G].vertexNormals[v];
					h[G].push(E.a, E.b, E.c)
				}
				m && this.skinIndices.push(p[_.a], p[_.b], p[_.c]), g && this.skinWeights.push(d[_.a], d[_.b], d[_.c])
			}
			return this.computeGroups(t), this.verticesNeedUpdate = t.verticesNeedUpdate, this.normalsNeedUpdate = t.normalsNeedUpdate, this.colorsNeedUpdate = t.colorsNeedUpdate, this.uvsNeedUpdate = t.uvsNeedUpdate, this.groupsNeedUpdate = t.groupsNeedUpdate, this
		}
	});
	var Ka = 1;
	Object.assign(Et.prototype, e.prototype, {
		isBufferGeometry: !0,
		getIndex: function() {
			return this.index
		},
		setIndex: function(t) {
			Array.isArray(t) ? this.index = new(Gt(t) > 65535 ? bt : yt)(t, 1) : this.index = t
		},
		addAttribute: function(t, e) {
			if(e && e.isBufferAttribute || e && e.isInterleavedBufferAttribute) {
				if("index" !== t) return this.attributes[t] = e, this;
				this.setIndex(e)
			} else this.addAttribute(t, new dt(arguments[1], arguments[2]))
		},
		getAttribute: function(t) {
			return this.attributes[t]
		},
		removeAttribute: function(t) {
			return delete this.attributes[t], this
		},
		addGroup: function(t, e, n) {
			this.groups.push({
				start: t,
				count: e,
				materialIndex: void 0 !== n ? n : 0
			})
		},
		clearGroups: function() {
			this.groups = []
		},
		setDrawRange: function(t, e) {
			this.drawRange.start = t, this.drawRange.count = e
		},
		applyMatrix: function(t) {
			var e = this.attributes.position;
			void 0 !== e && (t.applyToBufferAttribute(e), e.needsUpdate = !0);
			var n = this.attributes.normal;
			return void 0 !== n && ((new o).getNormalMatrix(t).applyToBufferAttribute(n), n.needsUpdate = !0), null !== this.boundingBox && this.computeBoundingBox(), null !== this.boundingSphere && this.computeBoundingSphere(), this
		},
		rotateX: function() {
			var t = new i;
			return function(e) {
				return t.makeRotationX(e), this.applyMatrix(t), this
			}
		}(),
		rotateY: function() {
			var t = new i;
			return function(e) {
				return t.makeRotationY(e), this.applyMatrix(t), this
			}
		}(),
		rotateZ: function() {
			var t = new i;
			return function(e) {
				return t.makeRotationZ(e), this.applyMatrix(t), this
			}
		}(),
		translate: function() {
			var t = new i;
			return function(e, n, i) {
				return t.makeTranslation(e, n, i), this.applyMatrix(t), this
			}
		}(),
		scale: function() {
			var t = new i;
			return function(e, n, i) {
				return t.makeScale(e, n, i), this.applyMatrix(t), this
			}
		}(),
		lookAt: function() {
			var t = new ct;
			return function(e) {
				t.lookAt(e), t.updateMatrix(), this.applyMatrix(t.matrix)
			}
		}(),
		center: function() {
			this.computeBoundingBox();
			var t = this.boundingBox.getCenter().negate();
			return this.translate(t.x, t.y, t.z), t
		},
		st: function(t) {
			var e = t.geometry;
			if(t.isPoints || t.isLine) {
				var n = new wt(3 * e.vertices.length, 3),
					i = new wt(3 * e.colors.length, 3);
				if(this.addAttribute("position", n.copyVector3sArray(e.vertices)), this.addAttribute("color", i.copyColorsArray(e.colors)), e.lineDistances && e.lineDistances.length === e.vertices.length) {
					var r = new wt(e.lineDistances.length, 1);
					this.addAttribute("lineDistance", r.copyArray(e.lineDistances))
				}
				null !== e.boundingSphere && (this.boundingSphere = e.boundingSphere.clone()), null !== e.boundingBox && (this.boundingBox = e.boundingBox.clone())
			} else t.isMesh && e && e.isGeometry && this.fromGeometry(e);
			return this
		},
		setFromPoints: function(t) {
			for(var e = [], n = 0, i = t.length; n < i; n++) {
				var r = t[n];
				e.push(r.x, r.y, r.z || 0)
			}
			return this.addAttribute("position", new wt(e, 3)), this
		},
		updateFromObject: function(t) {
			var e = t.geometry;
			if(t.isMesh) {
				var n = e.__directGeometry;
				if(!0 === e.elementsNeedUpdate && (n = void 0, e.elementsNeedUpdate = !1), void 0 === n) return this.fromGeometry(e);
				n.verticesNeedUpdate = e.verticesNeedUpdate, n.normalsNeedUpdate = e.normalsNeedUpdate, n.colorsNeedUpdate = e.colorsNeedUpdate, n.uvsNeedUpdate = e.uvsNeedUpdate, n.groupsNeedUpdate = e.groupsNeedUpdate, e.verticesNeedUpdate = !1, e.normalsNeedUpdate = !1, e.colorsNeedUpdate = !1, e.uvsNeedUpdate = !1, e.groupsNeedUpdate = !1, e = n
			}
			var i;
			return !0 === e.verticesNeedUpdate && (void 0 !== (i = this.attributes.position) && (i.copyVector3sArray(e.vertices), i.needsUpdate = !0), e.verticesNeedUpdate = !1), !0 === e.normalsNeedUpdate && (void 0 !== (i = this.attributes.normal) && (i.copyVector3sArray(e.normals), i.needsUpdate = !0), e.normalsNeedUpdate = !1), !0 === e.colorsNeedUpdate && (void 0 !== (i = this.attributes.color) && (i.copyColorsArray(e.colors), i.needsUpdate = !0), e.colorsNeedUpdate = !1), e.uvsNeedUpdate && (void 0 !== (i = this.attributes.uv) && (i.copyVector2sArray(e.uvs), i.needsUpdate = !0), e.uvsNeedUpdate = !1), e.lineDistancesNeedUpdate && (void 0 !== (i = this.attributes.lineDistance) && (i.copyArray(e.lineDistances), i.needsUpdate = !0), e.lineDistancesNeedUpdate = !1), e.groupsNeedUpdate && (e.computeGroups(t.geometry), this.groups = e.groups, e.groupsNeedUpdate = !1), this
		},
		fromGeometry: function(t) {
			return t.__directGeometry = (new St).fromGeometry(t), this.fromDirectGeometry(t.__directGeometry)
		},
		fromDirectGeometry: function(t) {
			var e = new Float32Array(3 * t.vertices.length);
			if(this.addAttribute("position", new dt(e, 3).copyVector3sArray(t.vertices)), t.normals.length > 0) {
				var n = new Float32Array(3 * t.normals.length);
				this.addAttribute("normal", new dt(n, 3).copyVector3sArray(t.normals))
			}
			if(t.colors.length > 0) {
				var i = new Float32Array(3 * t.colors.length);
				this.addAttribute("color", new dt(i, 3).copyColorsArray(t.colors))
			}
			if(t.uvs.length > 0) {
				var r = new Float32Array(2 * t.uvs.length);
				this.addAttribute("uv", new dt(r, 2).copyVector2sArray(t.uvs))
			}
			if(t.uvs2.length > 0) {
				var a = new Float32Array(2 * t.uvs2.length);
				this.addAttribute("uv2", new dt(a, 2).copyVector2sArray(t.uvs2))
			}
			if(t.indices.length > 0) {
				var o = new(Gt(t.indices) > 65535 ? Uint32Array : Uint16Array)(3 * t.indices.length);
				this.setIndex(new dt(o, 1).copyIndicesArray(t.indices))
			}
			this.groups = t.groups;
			for(var s in t.morphTargets) {
				for(var l = [], c = t.morphTargets[s], h = 0, u = c.length; h < u; h++) {
					var f = c[h],
						p = new wt(3 * f.length, 3);
					l.push(p.copyVector3sArray(f))
				}
				this.morphAttributes[s] = l
			}
			if(t.skinIndices.length > 0) {
				var d = new wt(4 * t.skinIndices.length, 4);
				this.addAttribute("skinIndex", d.copyVector4sArray(t.skinIndices))
			}
			if(t.skinWeights.length > 0) {
				var m = new wt(4 * t.skinWeights.length, 4);
				this.addAttribute("skinWeight", m.copyVector4sArray(t.skinWeights))
			}
			return null !== t.boundingSphere && (this.boundingSphere = t.boundingSphere.clone()), null !== t.boundingBox && (this.boundingBox = t.boundingBox.clone()), this
		},
		computeBoundingBox: function() {
			null === this.boundingBox && (this.boundingBox = new et);
			var t = this.attributes.position;
			void 0 !== t ? this.boundingBox.setFromBufferAttribute(t) : this.boundingBox.makeEmpty(), isNaN(this.boundingBox.min.x) || isNaN(this.boundingBox.min.y) || isNaN(this.boundingBox.min.z)
		},
		computeBoundingSphere: function() {
			var t = new et,
				e = new a;
			return function() {
				null === this.boundingSphere && (this.boundingSphere = new nt);
				var n = this.attributes.position;
				if(n) {
					var i = this.boundingSphere.center;
					t.setFromBufferAttribute(n), t.getCenter(i);
					for(var r = 0, a = 0, o = n.count; a < o; a++) e.x = n.getX(a), e.y = n.getY(a), e.z = n.getZ(a), r = Math.max(r, i.distanceToSquared(e));
					this.boundingSphere.radius = Math.sqrt(r), isNaN(this.boundingSphere.radius)
				}
			}
		}(),
		computeFaceNormals: function() {},
		computeVertexNormals: function() {
			var t = this.index,
				e = this.attributes,
				n = this.groups;
			if(e.position) {
				var i = e.position.array;
				if(void 0 === e.normal) this.addAttribute("normal", new dt(new Float32Array(i.length), 3));
				else
					for(var r = e.normal.array, o = 0, s = r.length; o < s; o++) r[o] = 0;
				var l, c, h, u = e.normal.array,
					f = new a,
					p = new a,
					d = new a,
					m = new a,
					g = new a;
				if(t) {
					var v = t.array;
					0 === n.length && this.addGroup(0, v.length);
					for(var _ = 0, y = n.length; _ < y; ++_)
						for(var x = n[_], b = x.start, o = b, s = b + x.count; o < s; o += 3) l = 3 * v[o + 0], c = 3 * v[o + 1], h = 3 * v[o + 2], f.fromArray(i, l), p.fromArray(i, c), d.fromArray(i, h), m.subVectors(d, p), g.subVectors(f, p), m.cross(g), u[l] += m.x, u[l + 1] += m.y, u[l + 2] += m.z, u[c] += m.x, u[c + 1] += m.y, u[c + 2] += m.z, u[h] += m.x, u[h + 1] += m.y, u[h + 2] += m.z
				} else
					for(var o = 0, s = i.length; o < s; o += 9) f.fromArray(i, o), p.fromArray(i, o + 3), d.fromArray(i, o + 6), m.subVectors(d, p), g.subVectors(f, p), m.cross(g), u[o] = m.x, u[o + 1] = m.y, u[o + 2] = m.z, u[o + 3] = m.x, u[o + 4] = m.y, u[o + 5] = m.z, u[o + 6] = m.x, u[o + 7] = m.y, u[o + 8] = m.z;
				this.normalizeNormals(), e.normal.needsUpdate = !0
			}
		},
		merge: function(t, e) {
			if(t && t.isBufferGeometry) {
				void 0 === e && (e = 0);
				var n = this.attributes;
				for(var i in n)
					if(void 0 !== t.attributes[i])
						for(var r = n[i].array, a = t.attributes[i], o = a.array, s = 0, l = a.itemSize * e; s < o.length; s++, l++) r[l] = o[s];
				return this
			}
		},
		normalizeNormals: function() {
			var t = new a;
			return function() {
				for(var e = this.attributes.normal, n = 0, i = e.count; n < i; n++) t.x = e.getX(n), t.y = e.getY(n), t.z = e.getZ(n), t.normalize(), e.setXYZ(n, t.x, t.y, t.z)
			}
		}(),
		toNonIndexed: function() {
			if(null === this.index) return this;
			var t = new Et,
				e = this.index.array,
				n = this.attributes;
			for(var i in n) {
				for(var r = n[i], a = r.array, o = r.itemSize, s = new a.constructor(e.length * o), l = 0, c = 0, h = 0, u = e.length; h < u; h++) {
					l = e[h] * o;
					for(var f = 0; f < o; f++) s[c++] = a[l++]
				}
				t.addAttribute(i, new dt(s, o))
			}
			return t
		},
		toJSON: function() {
			var t = {
				metadata: {
					version: 4.5,
					type: "BufferGeometry",
					generator: "BufferGeometry.toJSON"
				}
			};
			if(t.uuid = this.uuid, t.type = this.type, "" !== this.name && (t.name = this.name), void 0 !== this.parameters) {
				var e = this.parameters;
				for(var n in e) void 0 !== e[n] && (t[n] = e[n]);
				return t
			}
			t.data = {
				attributes: {}
			};
			var i = this.index;
			if(null !== i) {
				o = Array.prototype.slice.call(i.array);
				t.data.index = {
					type: i.array.constructor.name,
					array: o
				}
			}
			var r = this.attributes;
			for(var n in r) {
				var a = r[n],
					o = Array.prototype.slice.call(a.array);
				t.data.attributes[n] = {
					itemSize: a.itemSize,
					type: a.array.constructor.name,
					array: o,
					normalized: a.normalized
				}
			}
			var s = this.groups;
			s.length > 0 && (t.data.groups = JSON.parse(JSON.stringify(s)));
			var l = this.boundingSphere;
			return null !== l && (t.data.boundingSphere = {
				center: l.center.toArray(),
				radius: l.radius
			}), t
		},
		clone: function() {
			return(new Et).copy(this)
		},
		copy: function(t) {
			var e, n, i;
			this.index = null, this.attributes = {}, this.morphAttributes = {}, this.groups = [], this.boundingBox = null, this.boundingSphere = null, this.name = t.name;
			var r = t.index;
			null !== r && this.setIndex(r.clone());
			var a = t.attributes;
			for(e in a) {
				var o = a[e];
				this.addAttribute(e, o.clone())
			}
			var s = t.morphAttributes;
			for(e in s) {
				var l = [],
					c = s[e];
				for(n = 0, i = c.length; n < i; n++) l.push(c[n].clone());
				this.morphAttributes[e] = l
			}
			var h = t.groups;
			for(n = 0, i = h.length; n < i; n++) {
				var u = h[n];
				this.addGroup(u.start, u.count, u.materialIndex)
			}
			var f = t.boundingBox;
			null !== f && (this.boundingBox = f.clone());
			var p = t.boundingSphere;
			return null !== p && (this.boundingSphere = p.clone()), this.drawRange.start = t.drawRange.start, this.drawRange.count = t.drawRange.count, this
		},
		dispose: function() {
			this.dispatchEvent({
				type: "dispose"
			})
		}
	}), (Tt.prototype = Object.create(pt.prototype)).constructor = Tt, At.prototype = Object.create(Et.prototype), At.prototype.constructor = At, (Lt.prototype = Object.create(pt.prototype)).constructor = Lt, Ct.prototype = Object.create(Et.prototype), Ct.prototype.constructor = Ct, Pt.prototype = Object.create(Q.prototype), Pt.prototype.constructor = Pt, Pt.prototype.isMal = !0, Pt.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.color.copy(t.color), this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.specularMap = t.specularMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.combine = t.combine, this.reflectivity = t.reflectivity, this.refractionRatio = t.refractionRatio, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this
	}, It.prototype = Object.create(Q.prototype), It.prototype.constructor = It, It.prototype.isShaderMaterial = !0, It.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.fragmentShader = t.fragmentShader, this.vertexShader = t.vertexShader, this.uniforms = Wa.clone(t.uniforms), this.defines = t.defines, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.lights = t.lights, this.clipping = t.clipping, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.morphNormals = t.morphNormals, this.extensions = t.extensions, this
	}, It.prototype.toJSON = function(t) {
		var e = Q.prototype.toJSON.call(this, t);
		return e.uniforms = this.uniforms, e.vertexShader = this.vertexShader, e.fragmentShader = this.fragmentShader, e
	}, Object.assign(Rt.prototype, {
		set: function(t, e) {
			return this.origin.copy(t), this.direction.copy(e), this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.origin.copy(t.origin), this.direction.copy(t.direction), this
		},
		at: function(t, e) {
			return(e || new a).copy(this.direction).multiplyScalar(t).add(this.origin)
		},
		lookAt: function(t) {
			return this.direction.copy(t).sub(this.origin).normalize(), this
		},
		recast: function() {
			var t = new a;
			return function(e) {
				return this.origin.copy(this.at(e, t)), this
			}
		}(),
		closestPointToPoint: function(t, e) {
			var n = e || new a;
			n.subVectors(t, this.origin);
			var i = n.dot(this.direction);
			return i < 0 ? n.copy(this.origin) : n.copy(this.direction).multiplyScalar(i).add(this.origin)
		},
		distanceToPoint: function(t) {
			return Math.sqrt(this.distanceSqToPoint(t))
		},
		distanceSqToPoint: function() {
			var t = new a;
			return function(e) {
				var n = t.subVectors(e, this.origin).dot(this.direction);
				return n < 0 ? this.origin.distanceToSquared(e) : (t.copy(this.direction).multiplyScalar(n).add(this.origin), t.distanceToSquared(e))
			}
		}(),
		distanceSqToSegment: function() {
			var t = new a,
				e = new a,
				n = new a;
			return function(i, r, a, o) {
				t.copy(i).add(r).multiplyScalar(.5), e.copy(r).sub(i).normalize(), n.copy(this.origin).sub(t);
				var s, l, c, h, u = .5 * i.distanceTo(r),
					f = -this.direction.dot(e),
					p = n.dot(this.direction),
					d = -n.dot(e),
					m = n.lengthSq(),
					g = Math.abs(1 - f * f);
				if(g > 0)
					if(s = f * d - p, l = f * p - d, h = u * g, s >= 0)
						if(l >= -h)
							if(l <= h) {
								var v = 1 / g;
								c = (s *= v) * (s + f * (l *= v) + 2 * p) + l * (f * s + l + 2 * d) + m
							} else l = u, c = -(s = Math.max(0, -(f * l + p))) * s + l * (l + 2 * d) + m;
				else l = -u, c = -(s = Math.max(0, -(f * l + p))) * s + l * (l + 2 * d) + m;
				else l <= -h ? c = -(s = Math.max(0, -(-f * u + p))) * s + (l = s > 0 ? -u : Math.min(Math.max(-u, -d), u)) * (l + 2 * d) + m : l <= h ? (s = 0, c = (l = Math.min(Math.max(-u, -d), u)) * (l + 2 * d) + m) : c = -(s = Math.max(0, -(f * u + p))) * s + (l = s > 0 ? u : Math.min(Math.max(-u, -d), u)) * (l + 2 * d) + m;
				else l = f > 0 ? -u : u, c = -(s = Math.max(0, -(f * l + p))) * s + l * (l + 2 * d) + m;
				return a && a.copy(this.direction).multiplyScalar(s).add(this.origin), o && o.copy(e).multiplyScalar(l).add(t), c
			}
		}(),
		intersectSphere: function() {
			var t = new a;
			return function(e, n) {
				t.subVectors(e.center, this.origin);
				var i = t.dot(this.direction),
					r = t.dot(t) - i * i,
					a = e.radius * e.radius;
				if(r > a) return null;
				var o = Math.sqrt(a - r),
					s = i - o,
					l = i + o;
				return s < 0 && l < 0 ? null : s < 0 ? this.at(l, n) : this.at(s, n)
			}
		}(),
		intersectsSphere: function(t) {
			return this.distanceToPoint(t.center) <= t.radius
		},
		distanceToPlane: function(t) {
			var e = t.normal.dot(this.direction);
			if(0 === e) return 0 === t.distanceToPoint(this.origin) ? 0 : null;
			var n = -(this.origin.dot(t.normal) + t.constant) / e;
			return n >= 0 ? n : null
		},
		intersectPlane: function(t, e) {
			var n = this.distanceToPlane(t);
			return null === n ? null : this.at(n, e)
		},
		intersectsPlane: function(t) {
			var e = t.distanceToPoint(this.origin);
			return 0 === e || t.normal.dot(this.direction) * e < 0
		},
		intersectBox: function(t, e) {
			var n, i, r, a, o, s, l = 1 / this.direction.x,
				c = 1 / this.direction.y,
				h = 1 / this.direction.z,
				u = this.origin;
			return l >= 0 ? (n = (t.min.x - u.x) * l, i = (t.max.x - u.x) * l) : (n = (t.max.x - u.x) * l, i = (t.min.x - u.x) * l), c >= 0 ? (r = (t.min.y - u.y) * c, a = (t.max.y - u.y) * c) : (r = (t.max.y - u.y) * c, a = (t.min.y - u.y) * c), n > a || r > i ? null : ((r > n || n !== n) && (n = r), (a < i || i !== i) && (i = a), h >= 0 ? (o = (t.min.z - u.z) * h, s = (t.max.z - u.z) * h) : (o = (t.max.z - u.z) * h, s = (t.min.z - u.z) * h), n > s || o > i ? null : ((o > n || n !== n) && (n = o), (s < i || i !== i) && (i = s), i < 0 ? null : this.at(n >= 0 ? n : i, e)))
		},
		intersectsBox: function() {
			var t = new a;
			return function(e) {
				return null !== this.intersectBox(e, t)
			}
		}(),
		intersectTriangle: function() {
			var t = new a,
				e = new a,
				n = new a,
				i = new a;
			return function(r, a, o, s, l) {
				e.subVectors(a, r), n.subVectors(o, r), i.crossVectors(e, n);
				var c, h = this.direction.dot(i);
				if(h > 0) {
					if(s) return null;
					c = 1
				} else {
					if(!(h < 0)) return null;
					c = -1, h = -h
				}
				t.subVectors(this.origin, r);
				var u = c * this.direction.dot(n.crossVectors(t, n));
				if(u < 0) return null;
				var f = c * this.direction.dot(e.cross(t));
				if(f < 0) return null;
				if(u + f > h) return null;
				var p = -c * t.dot(i);
				return p < 0 ? null : this.at(p / h, l)
			}
		}(),
		applyMatrix4: function(t) {
			return this.origin.applyMatrix4(t), this.direction.transformDirection(t), this
		},
		equals: function(t) {
			return t.origin.equals(this.origin) && t.direction.equals(this.direction)
		}
	}), Object.assign(Ot.prototype, {
		set: function(t, e) {
			return this.start.copy(t), this.end.copy(e), this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.start.copy(t.start), this.end.copy(t.end), this
		},
		getCenter: function(t) {
			return(t || new a).addVectors(this.start, this.end).multiplyScalar(.5)
		},
		delta: function(t) {
			return(t || new a).subVectors(this.end, this.start)
		},
		distanceSq: function() {
			return this.start.distanceToSquared(this.end)
		},
		distance: function() {
			return this.start.distanceTo(this.end)
		},
		at: function(t, e) {
			var n = e || new a;
			return this.delta(n).multiplyScalar(t).add(this.start)
		},
		closestPointToPointParameter: function() {
			var t = new a,
				e = new a;
			return function(n, i) {
				t.subVectors(n, this.start), e.subVectors(this.end, this.start);
				var r = e.dot(e),
					a = e.dot(t) / r;
				return i && (a = Oa.clamp(a, 0, 1)), a
			}
		}(),
		closestPointToPoint: function(t, e, n) {
			var i = this.closestPointToPointParameter(t, e),
				r = n || new a;
			return this.delta(r).multiplyScalar(i).add(this.start)
		},
		applyMatrix4: function(t) {
			return this.start.applyMatrix4(t), this.end.applyMatrix4(t), this
		},
		equals: function(t) {
			return t.start.equals(this.start) && t.end.equals(this.end)
		}
	}), Object.assign(Nt, {
		normal: function() {
			var t = new a;
			return function(e, n, i, r) {
				var o = r || new a;
				o.subVectors(i, n), t.subVectors(e, n), o.cross(t);
				var s = o.lengthSq();
				return s > 0 ? o.multiplyScalar(1 / Math.sqrt(s)) : o.set(0, 0, 0)
			}
		}(),
		barycoordFromPoint: function() {
			var t = new a,
				e = new a,
				n = new a;
			return function(i, r, o, s, l) {
				t.subVectors(s, r), e.subVectors(o, r), n.subVectors(i, r);
				var c = t.dot(t),
					h = t.dot(e),
					u = t.dot(n),
					f = e.dot(e),
					p = e.dot(n),
					d = c * f - h * h,
					m = l || new a;
				if(0 === d) return m.set(-2, -1, -1);
				var g = 1 / d,
					v = (f * u - h * p) * g,
					_ = (c * p - h * u) * g;
				return m.set(1 - v - _, _, v)
			}
		}(),
		containsPoint: function() {
			var t = new a;
			return function(e, n, i, r) {
				var a = Nt.barycoordFromPoint(e, n, i, r, t);
				return a.x >= 0 && a.y >= 0 && a.x + a.y <= 1
			}
		}()
	}), Object.assign(Nt.prototype, {
		set: function(t, e, n) {
			return this.a.copy(t), this.b.copy(e), this.c.copy(n), this
		},
		setFromPointsAndIndices: function(t, e, n, i) {
			return this.a.copy(t[e]), this.b.copy(t[n]), this.c.copy(t[i]), this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.a.copy(t.a), this.b.copy(t.b), this.c.copy(t.c), this
		},
		area: function() {
			var t = new a,
				e = new a;
			return function() {
				return t.subVectors(this.c, this.b), e.subVectors(this.a, this.b), .5 * t.cross(e).length()
			}
		}(),
		midpoint: function(t) {
			return(t || new a).addVectors(this.a, this.b).add(this.c).multiplyScalar(1 / 3)
		},
		normal: function(t) {
			return Nt.normal(this.a, this.b, this.c, t)
		},
		plane: function(t) {
			return(t || new it).setFromCoplanarPoints(this.a, this.b, this.c)
		},
		barycoordFromPoint: function(t, e) {
			return Nt.barycoordFromPoint(t, this.a, this.b, this.c, e)
		},
		containsPoint: function(t) {
			return Nt.containsPoint(t, this.a, this.b, this.c)
		},
		closestPointToPoint: function() {
			var t = new it,
				e = [new Ot, new Ot, new Ot],
				n = new a,
				i = new a;
			return function(r, o) {
				var s = o || new a,
					l = 1 / 0;
				if(t.setFromCoplanarPoints(this.a, this.b, this.c), t.projectPoint(r, n), !0 === this.containsPoint(n)) s.copy(n);
				else {
					e[0].set(this.a, this.b), e[1].set(this.b, this.c), e[2].set(this.c, this.a);
					for(var c = 0; c < e.length; c++) {
						e[c].closestPointToPoint(n, !0, i);
						var h = n.distanceToSquared(i);
						h < l && (l = h, s.copy(i))
					}
				}
				return s
			}
		}(),
		equals: function(t) {
			return t.a.equals(this.a) && t.b.equals(this.b) && t.c.equals(this.c)
		}
	}), Dt.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: Dt,
		isMesh: !0,
		setDrawMode: function(t) {
			this.drawMode = t
		},
		copy: function(t) {
			return ct.prototype.copy.call(this, t), this.drawMode = t.drawMode, void 0 !== t.morphTargetInfluences && (this.morphTargetInfluences = t.morphTargetInfluences.slice()), void 0 !== t.morphTargetDictionary && (this.morphTargetDictionary = Object.assign({}, t.morphTargetDictionary)), this
		},
		updateMorphTargets: function() {
			var t, e, n, i = this.geometry;
			if(i.isBufferGeometry) {
				var r = i.morphAttributes,
					a = Object.keys(r);
				if(a.length > 0) {
					var o = r[a[0]];
					if(void 0 !== o)
						for(this.morphTargetInfluences = [], this.morphTargetDictionary = {}, t = 0, e = o.length; t < e; t++) n = o[t].name || String(t), this.morphTargetInfluences.push(0), this.morphTargetDictionary[n] = t
				}
			} else {
				var s = i.morphTargets;
				if(void 0 !== s && s.length > 0)
					for(this.morphTargetInfluences = [], this.morphTargetDictionary = {}, t = 0, e = s.length; t < e; t++) n = s[t].name || String(t), this.morphTargetInfluences.push(0), this.morphTargetDictionary[n] = t
			}
		},
		raycast: function() {
			function t(t, e, n, i, r, a, o) {
				return Nt.barycoordFromPoint(t, e, n, i, _), r.multiplyScalar(_.x), a.multiplyScalar(_.y), o.multiplyScalar(_.z), r.add(a).add(o), r.clone()
			}

			function e(t, e, n, i, r, a, o, s) {
				if(null === (e.side === ji ? i.intersectTriangle(o, a, r, !0, s) : i.intersectTriangle(r, a, o, e.side !== Hi, s))) return null;
				x.copy(s), x.applyMatrix4(t.matrixWorld);
				var l = n.ray.origin.distanceTo(x);
				return l < n.near || l > n.far ? null : {
					distance: l,
					point: x.clone(),
					object: t
				}
			}

			function r(n, i, r, a, o, s, l, f) {
				c.fromBufferAttribute(a, s), h.fromBufferAttribute(a, l), u.fromBufferAttribute(a, f);
				var p = e(n, n.material, i, r, c, h, u, y);
				return p && (o && (m.fromBufferAttribute(o, s), g.fromBufferAttribute(o, l), v.fromBufferAttribute(o, f), p.uv = t(y, c, h, u, m, g, v)), p.face = new ft(s, l, f, Nt.normal(c, h, u)), p.faceIndex = s), p
			}
			var o = new i,
				s = new Rt,
				l = new nt,
				c = new a,
				h = new a,
				u = new a,
				f = new a,
				p = new a,
				d = new a,
				m = new n,
				g = new n,
				v = new n,
				_ = new a,
				y = new a,
				x = new a;
			return function(n, i) {
				var a = this.geometry,
					_ = this.material,
					x = this.matrixWorld;
				if(void 0 !== _ && (null === a.boundingSphere && a.computeBoundingSphere(), l.copy(a.boundingSphere), l.applyMatrix4(x), !1 !== n.ray.intersectsSphere(l) && (o.getInverse(x), s.copy(n.ray).applyMatrix4(o), null === a.boundingBox || !1 !== s.intersectsBox(a.boundingBox)))) {
					var b;
					if(a.isBufferGeometry) {
						var w, M, S, G, E, T = a.index,
							A = a.attributes.position,
							L = a.attributes.uv;
						if(null !== T)
							for(G = 0, E = T.count; G < E; G += 3) w = T.getX(G), M = T.getX(G + 1), S = T.getX(G + 2), (b = r(this, n, s, A, L, w, M, S)) && (b.faceIndex = Math.floor(G / 3), i.push(b));
						else if(void 0 !== A)
							for(G = 0, E = A.count; G < E; G += 3)(b = r(this, n, s, A, L, w = G, M = G + 1, S = G + 2)) && (b.index = w, i.push(b))
					} else if(a.isGeometry) {
						var C, P, I, R, O = Array.isArray(_),
							N = a.vertices,
							D = a.faces,
							z = a.faceVertexUvs[0];
						z.length > 0 && (R = z);
						for(var U = 0, F = D.length; U < F; U++) {
							var k = D[U],
								B = O ? _[k.materialIndex] : _;
							if(void 0 !== B) {
								if(C = N[k.a], P = N[k.b], I = N[k.c], !0 === B.morphTargets) {
									var V = a.morphTargets,
										j = this.morphTargetInfluences;
									c.set(0, 0, 0), h.set(0, 0, 0), u.set(0, 0, 0);
									for(var H = 0, W = V.length; H < W; H++) {
										var X = j[H];
										if(0 !== X) {
											var Y = V[H].vertices;
											c.addScaledVector(f.subVectors(Y[k.a], C), X), h.addScaledVector(p.subVectors(Y[k.b], P), X), u.addScaledVector(d.subVectors(Y[k.c], I), X)
										}
									}
									c.add(C), h.add(P), u.add(I), C = c, P = h, I = u
								}
								if(b = e(this, B, n, s, C, P, I, y)) {
									if(R && R[U]) {
										var q = R[U];
										m.copy(q[0]), g.copy(q[1]), v.copy(q[2]), b.uv = t(y, C, P, I, m, g, v)
									}
									b.face = k, b.faceIndex = U, i.push(b)
								}
							}
						}
					}
				}
			}
		}(),
		clone: function() {
			return new this.constructor(this.geometry, this.material).copy(this)
		}
	});
	var Qa = 0;
	de.prototype = Object.assign(Object.create(ht.prototype), {
		constructor: de,
		isPa: !0,
		copy: function(t, e) {
			return ht.prototype.copy.call(this, t, e), this.fov = t.fov, this.zoom = t.zoom, this.near = t.near, this.far = t.far, this.focus = t.focus, this.aspect = t.aspect, this.view = null === t.view ? null : Object.assign({}, t.view), this.filmGauge = t.filmGauge, this.filmOffset = t.filmOffset, this
		},
		setFocalLength: function(t) {
			var e = .5 * this.getFilmHeight() / t;
			this.fov = 2 * Oa.RAD2DEG * Math.atan(e), this.ux()
		},
		getFocalLength: function() {
			var t = Math.tan(.5 * Oa.DEG2RAD * this.fov);
			return .5 * this.getFilmHeight() / t
		},
		getEffectiveFOV: function() {
			return 2 * Oa.RAD2DEG * Math.atan(Math.tan(.5 * Oa.DEG2RAD * this.fov) / this.zoom)
		},
		getFilmWidth: function() {
			return this.filmGauge * Math.min(this.aspect, 1)
		},
		getFilmHeight: function() {
			return this.filmGauge / Math.max(this.aspect, 1)
		},
		setViewOffset: function(t, e, n, i, r, a) {
			this.aspect = t / e, null === this.view && (this.view = {
				enabled: !0,
				fullWidth: 1,
				fullHeight: 1,
				offsetX: 0,
				offsetY: 0,
				width: 1,
				height: 1
			}), this.view.enabled = !0, this.view.fullWidth = t, this.view.fullHeight = e, this.view.offsetX = n, this.view.offsetY = i, this.view.width = r, this.view.height = a, this.ux()
		},
		clearViewOffset: function() {
			null !== this.view && (this.view.enabled = !1), this.ux()
		},
		ux: function() {
			var t = this.near,
				e = t * Math.tan(.5 * Oa.DEG2RAD * this.fov) / this.zoom,
				n = 2 * e,
				i = this.aspect * n,
				r = -.5 * i,
				a = this.view;
			if(null !== this.view && this.view.enabled) {
				var o = a.fullWidth,
					s = a.fullHeight;
				r += a.offsetX * i / o, e -= a.offsetY * n / s, i *= a.width / o, n *= a.height / s
			}
			var l = this.filmOffset;
			0 !== l && (r += t * l / this.getFilmWidth()), this.projectionMatrix.makePerspective(r, r + i, e, e - n, t, this.far)
		},
		toJSON: function(t) {
			var e = ct.prototype.toJSON.call(this, t);
			return e.object.fov = this.fov, e.object.zoom = this.zoom, e.object.near = this.near, e.object.far = this.far, e.object.focus = this.focus, e.object.aspect = this.aspect, null !== this.view && (e.object.view = Object.assign({}, this.view)), e.object.filmGauge = this.filmGauge, e.object.filmOffset = this.filmOffset, e
		}
	}), me.prototype = Object.assign(Object.create(de.prototype), {
		constructor: me,
		isArrayCamera: !0
	}), xe.prototype.isFog = !0, xe.prototype.clone = function() {
		return new xe(this.color.getHex(), this.near, this.far)
	}, xe.prototype.toJSON = function() {
		return {
			type: "Fog",
			color: this.color.getHex(),
			near: this.near,
			far: this.far
		}
	}, be.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: be,
		copy: function(t, e) {
			return ct.prototype.copy.call(this, t, e), null !== t.background && (this.background = t.background.clone()), null !== t.fog && (this.fog = t.fog.clone()), null !== t.overrideMaterial && (this.overrideMaterial = t.overrideMaterial.clone()), this.autoUpdate = t.autoUpdate, this.matrixAutoUpdate = t.matrixAutoUpdate, this
		},
		toJSON: function(t) {
			var e = ct.prototype.toJSON.call(this, t);
			return null !== this.background && (e.object.background = this.background.toJSON(t)), null !== this.fog && (e.object.fog = this.fog.toJSON()), e
		}
	}), we.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: we,
		isLensFlare: !0,
		copy: function(t) {
			ct.prototype.copy.call(this, t), this.positionScreen.copy(t.positionScreen), this.customUpdateCallback = t.customUpdateCallback;
			for(var e = 0, n = t.lensFlares.length; e < n; e++) this.lensFlares.push(t.lensFlares[e]);
			return this
		},
		add: function(t, e, n, i, r, a) {
			void 0 === e && (e = -1), void 0 === n && (n = 0), void 0 === a && (a = 1), void 0 === r && (r = new Y(16777215)), void 0 === i && (i = qi), n = Math.min(n, Math.max(0, n)), this.lensFlares.push({
				texture: t,
				size: e,
				distance: n,
				x: 0,
				y: 0,
				z: 0,
				scale: 1,
				rotation: 0,
				opacity: a,
				color: r,
				blending: i
			})
		},
		updateLensFlares: function() {
			var t, e, n = this.lensFlares.length,
				i = 2 * -this.positionScreen.x,
				r = 2 * -this.positionScreen.y;
			for(t = 0; t < n; t++)(e = this.lensFlares[t]).x = this.positionScreen.x + i * e.distance, e.y = this.positionScreen.y + r * e.distance, e.wantedRotation = e.x * Math.PI * .25, e.rotation += .25 * (e.wantedRotation - e.rotation)
		}
	}), Me.prototype = Object.create(Q.prototype), Me.prototype.constructor = Me, Me.prototype.isSpriteMaterial = !0, Me.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.color.copy(t.color), this.map = t.map, this.rotation = t.rotation, this
	}, Se.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: Se,
		isSprite: !0,
		raycast: function() {
			var t = new a,
				e = new a,
				n = new a;
			return function(i, r) {
				e.setFromMatrixPosition(this.matrixWorld), i.ray.closestPointToPoint(e, t), n.setFromMatrixScale(this.matrixWorld);
				var a = n.x * n.y / 4;
				if(!(e.distanceToSquared(t) > a)) {
					var o = i.ray.origin.distanceTo(t);
					o < i.near || o > i.far || r.push({
						distance: o,
						point: t.clone(),
						face: null,
						object: this
					})
				}
			}
		}(),
		clone: function() {
			return new this.constructor(this.material).copy(this)
		}
	}), Object.assign(Ge.prototype, {
		calculateInverses: function() {
			this.boneInverses = [];
			for(var t = 0, e = this.bones.length; t < e; t++) {
				var n = new i;
				this.bones[t] && n.getInverse(this.bones[t].matrixWorld), this.boneInverses.push(n)
			}
		},
		pose: function() {
			var t, e, n;
			for(e = 0, n = this.bones.length; e < n; e++)(t = this.bones[e]) && t.matrixWorld.getInverse(this.boneInverses[e]);
			for(e = 0, n = this.bones.length; e < n; e++)(t = this.bones[e]) && (t.parent && t.parent.isBone ? (t.matrix.getInverse(t.parent.matrixWorld), t.matrix.multiply(t.matrixWorld)) : t.matrix.copy(t.matrixWorld), t.matrix.decompose(t.position, t.quaternion, t.scale))
		},
		update: function() {
			var t = new i,
				e = new i;
			return function() {
				for(var n = this.bones, i = this.boneInverses, r = this.boneMatrices, a = this.boneTexture, o = 0, s = n.length; o < s; o++) {
					var l = n[o] ? n[o].matrixWorld : e;
					t.multiplyMatrices(l, i[o]), t.toArray(r, 16 * o)
				}
				void 0 !== a && (a.needsUpdate = !0)
			}
		}(),
		clone: function() {
			return new Ge(this.bones, this.boneInverses)
		}
	}), Ee.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: Ee,
		isBone: !0
	}), Te.prototype = Object.assign(Object.create(Dt.prototype), {
		constructor: Te,
		isSkinnedMesh: !0,
		initBones: function() {
			var t, e, n, i, r = [];
			if(this.geometry && void 0 !== this.geometry.bones) {
				for(n = 0, i = this.geometry.bones.length; n < i; n++) e = this.geometry.bones[n], t = new Ee, r.push(t), t.name = e.name, t.position.fromArray(e.pos), t.quaternion.fromArray(e.rotq), void 0 !== e.scl && t.scale.fromArray(e.scl);
				for(n = 0, i = this.geometry.bones.length; n < i; n++) - 1 !== (e = this.geometry.bones[n]).parent && null !== e.parent && void 0 !== r[e.parent] ? r[e.parent].add(r[n]) : this.add(r[n])
			}
			return this.uld(!0), r
		},
		bind: function(t, e) {
			this.skeleton = t, void 0 === e && (this.uld(!0), this.skeleton.calculateInverses(), e = this.matrixWorld), this.bindMatrix.copy(e), this.bindMatrixInverse.getInverse(e)
		},
		pose: function() {
			this.skeleton.pose()
		},
		normalizeSkinWeights: function() {
			var t, e;
			if(this.geometry && this.geometry.isGeometry)
				for(e = 0; e < this.geometry.skinWeights.length; e++) {
					var n = this.geometry.skinWeights[e];
					(t = 1 / n.manhattanLength()) !== 1 / 0 ? n.multiplyScalar(t) : n.set(1, 0, 0, 0)
				} else if(this.geometry && this.geometry.isBufferGeometry) {
					var i = new l,
						r = this.geometry.attributes.skinWeight;
					for(e = 0; e < r.count; e++) i.x = r.getX(e), i.y = r.getY(e), i.z = r.getZ(e), i.w = r.getW(e), (t = 1 / i.manhattanLength()) !== 1 / 0 ? i.multiplyScalar(t) : i.set(1, 0, 0, 0), r.setXYZW(e, i.x, i.y, i.z, i.w)
				}
		},
		uld: function(t) {
			Dt.prototype.uld.call(this, t), "attached" === this.bindMode ? this.bindMatrixInverse.getInverse(this.matrixWorld) : "detached" === this.bindMode && this.bindMatrixInverse.getInverse(this.bindMatrix)
		},
		clone: function() {
			return new this.constructor(this.geometry, this.material).copy(this)
		}
	}), Ae.prototype = Object.create(Q.prototype), Ae.prototype.constructor = Ae, Ae.prototype.isLineBasicMaterial = !0, Ae.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.color.copy(t.color), this.linewidth = t.linewidth, this.linecap = t.linecap, this.linejoin = t.linejoin, this
	}, Le.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: Le,
		isLine: !0,
		raycast: function() {
			var t = new i,
				e = new Rt,
				n = new nt;
			return function(i, r) {
				var o = i.linePrecision,
					s = o * o,
					l = this.geometry,
					c = this.matrixWorld;
				if(null === l.boundingSphere && l.computeBoundingSphere(), n.copy(l.boundingSphere), n.applyMatrix4(c), !1 !== i.ray.intersectsSphere(n)) {
					t.getInverse(c), e.copy(i.ray).applyMatrix4(t);
					var h = new a,
						u = new a,
						f = new a,
						p = new a,
						d = this && this.isLineSegments ? 2 : 1;
					if(l.isBufferGeometry) {
						var m = l.index,
							g = l.attributes.position.array;
						if(null !== m)
							for(var v = m.array, _ = 0, y = v.length - 1; _ < y; _ += d) {
								var x = v[_],
									b = v[_ + 1];
								h.fromArray(g, 3 * x), u.fromArray(g, 3 * b), (S = e.distanceSqToSegment(h, u, p, f)) > s || (p.applyMatrix4(this.matrixWorld), (G = i.ray.origin.distanceTo(p)) < i.near || G > i.far || r.push({
									distance: G,
									point: f.clone().applyMatrix4(this.matrixWorld),
									index: _,
									face: null,
									faceIndex: null,
									object: this
								}))
							} else
								for(var _ = 0, y = g.length / 3 - 1; _ < y; _ += d) h.fromArray(g, 3 * _), u.fromArray(g, 3 * _ + 3), (S = e.distanceSqToSegment(h, u, p, f)) > s || (p.applyMatrix4(this.matrixWorld), (G = i.ray.origin.distanceTo(p)) < i.near || G > i.far || r.push({
									distance: G,
									point: f.clone().applyMatrix4(this.matrixWorld),
									index: _,
									face: null,
									faceIndex: null,
									object: this
								}))
					} else if(l.isGeometry)
						for(var w = l.vertices, M = w.length, _ = 0; _ < M - 1; _ += d) {
							var S = e.distanceSqToSegment(w[_], w[_ + 1], p, f);
							if(!(S > s)) {
								p.applyMatrix4(this.matrixWorld);
								var G = i.ray.origin.distanceTo(p);
								G < i.near || G > i.far || r.push({
									distance: G,
									point: f.clone().applyMatrix4(this.matrixWorld),
									index: _,
									face: null,
									faceIndex: null,
									object: this
								})
							}
						}
				}
			}
		}(),
		clone: function() {
			return new this.constructor(this.geometry, this.material).copy(this)
		}
	}), Ce.prototype = Object.assign(Object.create(Le.prototype), {
		constructor: Ce,
		isLineSegments: !0
	}), Pe.prototype = Object.assign(Object.create(Le.prototype), {
		constructor: Pe,
		isLineLoop: !0
	}), Ie.prototype = Object.create(Q.prototype), Ie.prototype.constructor = Ie, Ie.prototype.isPointsMaterial = !0, Ie.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.color.copy(t.color), this.map = t.map, this.size = t.size, this.sizeAttenuation = t.sizeAttenuation, this
	}, Re.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: Re,
		isPoints: !0,
		raycast: function() {
			var t = new i,
				e = new Rt,
				n = new nt;
			return function(i, r) {
				function o(t, n) {
					var a = e.distanceSqToPoint(t);
					if(a < f) {
						var o = e.closestPointToPoint(t);
						o.applyMatrix4(c);
						var l = i.ray.origin.distanceTo(o);
						if(l < i.near || l > i.far) return;
						r.push({
							distance: l,
							distanceToRay: Math.sqrt(a),
							point: o.clone(),
							index: n,
							face: null,
							object: s
						})
					}
				}
				var s = this,
					l = this.geometry,
					c = this.matrixWorld,
					h = i.params.Points.threshold;
				if(null === l.boundingSphere && l.computeBoundingSphere(), n.copy(l.boundingSphere), n.applyMatrix4(c), n.radius += h, !1 !== i.ray.intersectsSphere(n)) {
					t.getInverse(c), e.copy(i.ray).applyMatrix4(t);
					var u = h / ((this.scale.x + this.scale.y + this.scale.z) / 3),
						f = u * u,
						p = new a;
					if(l.isBufferGeometry) {
						var d = l.index,
							m = l.attributes.position.array;
						if(null !== d)
							for(var g = d.array, v = 0, _ = g.length; v < _; v++) {
								var y = g[v];
								p.fromArray(m, 3 * y), o(p, y)
							} else
								for(var v = 0, x = m.length / 3; v < x; v++) p.fromArray(m, 3 * v), o(p, v)
					} else
						for(var b = l.vertices, v = 0, x = b.length; v < x; v++) o(b[v], v)
				}
			}
		}(),
		clone: function() {
			return new this.constructor(this.geometry, this.material).copy(this)
		}
	}), Oe.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: Oe
	}), (Ne.prototype = Object.create(s.prototype)).constructor = Ne, (De.prototype = Object.create(s.prototype)).constructor = De, De.prototype.isCompressedTexture = !0, (ze.prototype = Object.create(s.prototype)).constructor = ze, ze.prototype.isDepthTexture = !0, Ue.prototype = Object.create(Et.prototype), Ue.prototype.constructor = Ue;
	var $a = {
		area: function(t) {
			for(var e = t.length, n = 0, i = e - 1, r = 0; r < e; i = r++) n += t[i].x * t[r].y - t[r].x * t[i].y;
			return .5 * n
		},
		triangulate: function() {
			function t(t, e, n, i, r, a) {
				var o, s, l, c, h, u, f, p, d;
				if(s = t[a[e]].x, l = t[a[e]].y, c = t[a[n]].x, h = t[a[n]].y, u = t[a[i]].x, f = t[a[i]].y, (c - s) * (f - l) - (h - l) * (u - s) <= 0) return !1;
				var m, g, v, _, y, x, b, w, M, S, G, E, T, A, L;
				for(m = u - c, g = f - h, v = s - u, _ = l - f, y = c - s, x = h - l, o = 0; o < r; o++)
					if(p = t[a[o]].x, d = t[a[o]].y, !(p === s && d === l || p === c && d === h || p === u && d === f) && (b = p - s, w = d - l, M = p - c, S = d - h, G = p - u, E = d - f, L = m * S - g * M, T = y * w - x * b, A = v * E - _ * G, L >= -Number.EPSILON && A >= -Number.EPSILON && T >= -Number.EPSILON)) return !1;
				return !0
			}
			return function(e, n) {
				var i = e.length;
				if(i < 3) return null;
				var r, a, o, s = [],
					l = [],
					c = [];
				if($a.area(e) > 0)
					for(a = 0; a < i; a++) l[a] = a;
				else
					for(a = 0; a < i; a++) l[a] = i - 1 - a;
				var h = i,
					u = 2 * h;
				for(a = h - 1; h > 2;) {
					if(u-- <= 0) return n ? c : s;
					if(r = a, h <= r && (r = 0), a = r + 1, h <= a && (a = 0), o = a + 1, h <= o && (o = 0), t(e, r, a, o, h, l)) {
						var f, p, d, m, g;
						for(f = l[r], p = l[a], d = l[o], s.push([e[f], e[p], e[d]]), c.push([l[r], l[a], l[o]]), m = a, g = a + 1; g < h; m++, g++) l[m] = l[g];
						u = 2 * --h
					}
				}
				return n ? c : s
			}
		}(),
		triangulateShape: function(t, e) {
			function n(t) {
				var e = t.length;
				e > 2 && t[e - 1].equals(t[0]) && t.pop()
			}

			function i(t, e, n) {
				return t.x !== e.x ? t.x < e.x ? t.x <= n.x && n.x <= e.x : e.x <= n.x && n.x <= t.x : t.y < e.y ? t.y <= n.y && n.y <= e.y : e.y <= n.y && n.y <= t.y
			}

			function r(t, e, n, r, a) {
				var o = e.x - t.x,
					s = e.y - t.y,
					l = r.x - n.x,
					c = r.y - n.y,
					h = t.x - n.x,
					u = t.y - n.y,
					f = s * l - o * c,
					p = s * h - o * u;
				if(Math.abs(f) > Number.EPSILON) {
					var d;
					if(f > 0) {
						if(p < 0 || p > f) return [];
						if((d = c * h - l * u) < 0 || d > f) return []
					} else {
						if(p > 0 || p < f) return [];
						if((d = c * h - l * u) > 0 || d < f) return []
					}
					if(0 === d) return !a || 0 !== p && p !== f ? [t] : [];
					if(d === f) return !a || 0 !== p && p !== f ? [e] : [];
					if(0 === p) return [n];
					if(p === f) return [r];
					var m = d / f;
					return [{
						x: t.x + m * o,
						y: t.y + m * s
					}]
				}
				if(0 !== p || c * h != l * u) return [];
				var g = 0 === o && 0 === s,
					v = 0 === l && 0 === c;
				if(g && v) return t.x !== n.x || t.y !== n.y ? [] : [t];
				if(g) return i(n, r, t) ? [t] : [];
				if(v) return i(t, e, n) ? [n] : [];
				var _, y, x, b, w, M, S, G;
				return 0 !== o ? (t.x < e.x ? (_ = t, x = t.x, y = e, b = e.x) : (_ = e, x = e.x, y = t, b = t.x), n.x < r.x ? (w = n, S = n.x, M = r, G = r.x) : (w = r, S = r.x, M = n, G = n.x)) : (t.y < e.y ? (_ = t, x = t.y, y = e, b = e.y) : (_ = e, x = e.y, y = t, b = t.y), n.y < r.y ? (w = n, S = n.y, M = r, G = r.y) : (w = r, S = r.y, M = n, G = n.y)), x <= S ? b < S ? [] : b === S ? a ? [] : [w] : b <= G ? [w, y] : [w, M] : x > G ? [] : x === G ? a ? [] : [_] : b <= G ? [_, y] : [_, M]
			}

			function a(t, e, n, i) {
				var r = e.x - t.x,
					a = e.y - t.y,
					o = n.x - t.x,
					s = n.y - t.y,
					l = i.x - t.x,
					c = i.y - t.y,
					h = r * s - a * o,
					u = r * c - a * l;
				if(Math.abs(h) > Number.EPSILON) {
					var f = l * s - c * o;
					return h > 0 ? u >= 0 && f >= 0 : u >= 0 || f >= 0
				}
				return u > 0
			}
			n(t), e.forEach(n);
			for(var o, s, l, c, h, u, f = {}, p = t.concat(), d = 0, m = e.length; d < m; d++) Array.prototype.push.apply(p, e[d]);
			for(o = 0, s = p.length; o < s; o++) f[h = p[o].x + ":" + p[o].y], f[h] = o;
			var g = function(t, e) {
					for(var n, i, o, s, l, c, h, u, f, p, d, m = t.concat(), g = [], v = [], _ = 0, y = e.length; _ < y; _++) g.push(_);
					for(var x = 0, b = 2 * g.length; g.length > 0 && !(--b < 0);)
						for(o = x; o < m.length; o++) {
							for(s = m[o], i = -1, _ = 0; _ < g.length; _++)
								if(c = g[_], h = s.x + ":" + s.y + ":" + c, void 0 === v[h]) {
									n = e[c];
									for(var w = 0; w < n.length; w++)
										if(l = n[w], function(t, e) {
												var i = m.length - 1,
													r = t - 1;
												r < 0 && (r = i);
												var o = t + 1;
												o > i && (o = 0);
												var s = a(m[t], m[r], m[o], n[e]);
												if(!s) return !1;
												var l = n.length - 1,
													c = e - 1;
												c < 0 && (c = l);
												var h = e + 1;
												return h > l && (h = 0), !!(s = a(n[e], n[c], n[h], m[t]))
											}(o, w) && ! function(t, e) {
												var n, i;
												for(n = 0; n < m.length; n++)
													if(i = n + 1, i %= m.length, r(t, e, m[n], m[i], !0).length > 0) return !0;
												return !1
											}(s, l) && ! function(t, n) {
												var i, a, o, s;
												for(i = 0; i < g.length; i++)
													for(a = e[g[i]], o = 0; o < a.length; o++)
														if(s = o + 1, s %= a.length, r(t, n, a[o], a[s], !0).length > 0) return !0;
												return !1
											}(s, l)) {
											i = w, g.splice(_, 1), u = m.slice(0, o + 1), f = m.slice(o), p = n.slice(i), d = n.slice(0, i + 1), m = u.concat(p).concat(d).concat(f), x = o;
											break
										}
									if(i >= 0) break;
									v[h] = !0
								}
							if(i >= 0) break
						}
					return m
				}(t, e),
				v = $a.triangulate(g, !1);
			for(o = 0, s = v.length; o < s; o++)
				for(c = v[o], l = 0; l < 3; l++) void 0 !== (u = f[h = c[l].x + ":" + c[l].y]) && (c[l] = u);
			return v.concat()
		},
		isClockWise: function(t) {
			return $a.area(t) < 0
		}
	};
	(Fe.prototype = Object.create(pt.prototype)).constructor = Fe, (ke.prototype = Object.create(Et.prototype)).constructor = ke, (Be.prototype = Object.create(pt.prototype)).constructor = Be, (Ve.prototype = Object.create(Et.prototype)).constructor = Ve, je.prototype = Object.create(Et.prototype), je.prototype.constructor = je, He.prototype = Object.create(pt.prototype), He.prototype.constructor = He, We.prototype = Object.create(Et.prototype), We.prototype.constructor = We, (Xe.prototype = Object.create(He.prototype)).constructor = Xe, (Ye.prototype = Object.create(We.prototype)).constructor = Ye, (qe.prototype = Object.create(pt.prototype)).constructor = qe, (Ze.prototype = Object.create(Et.prototype)).constructor = Ze;
	var to = Object.freeze({
		WireframeGeometry: Ue,
		SphereGeometry: Fe,
		SphereBufferGeometry: ke,
		PlaneGeometry: Lt,
		PlaneBufferGeometry: Ct,
		ShapeGeometry: Be,
		ShapeBufferGeometry: Ve,
		EdgesGeometry: je,
		ConeGeometry: Xe,
		ConeBufferGeometry: Ye,
		CylinderGeometry: He,
		CylinderBufferGeometry: We,
		CircleGeometry: qe,
		CircleBufferGeometry: Ze,
		BoxGeometry: Tt,
		By: At
	});
	(Je.prototype = Object.create(Q.prototype)).constructor = Je, Je.prototype.isShadowMaterial = !0, (Ke.prototype = Object.create(It.prototype)).constructor = Ke, Ke.prototype.isRawShaderMaterial = !0, Qe.prototype = Object.create(Q.prototype), Qe.prototype.constructor = Qe, Qe.prototype.isMeshStandardMaterial = !0, Qe.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.defines = {
			STANDARD: ""
		}, this.color.copy(t.color), this.roughness = t.roughness, this.metalness = t.metalness, this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.roughnessMap = t.roughnessMap, this.metalnessMap = t.metalnessMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.envMapIntensity = t.envMapIntensity, this.refractionRatio = t.refractionRatio, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.morphNormals = t.morphNormals, this
	}, ($e.prototype = Object.create(Qe.prototype)).constructor = $e, $e.prototype.isMeshPhysicalMaterial = !0, $e.prototype.copy = function(t) {
		return Qe.prototype.copy.call(this, t), this.defines = {
			PHYSICAL: ""
		}, this.reflectivity = t.reflectivity, this.clearCoat = t.clearCoat, this.clearCoatRoughness = t.clearCoatRoughness, this
	}, tn.prototype = Object.create(Q.prototype), tn.prototype.constructor = tn, tn.prototype.isMeshPhongMaterial = !0, tn.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.color.copy(t.color), this.specular.copy(t.specular), this.shininess = t.shininess, this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.specularMap = t.specularMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.combine = t.combine, this.reflectivity = t.reflectivity, this.refractionRatio = t.refractionRatio, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.morphNormals = t.morphNormals, this
	}, (en.prototype = Object.create(tn.prototype)).constructor = en, en.prototype.isMeshToonMaterial = !0, en.prototype.copy = function(t) {
		return tn.prototype.copy.call(this, t), this.gradientMap = t.gradientMap, this
	}, (nn.prototype = Object.create(Q.prototype)).constructor = nn, nn.prototype.isMeshNormalMaterial = !0, nn.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.morphNormals = t.morphNormals, this
	}, (rn.prototype = Object.create(Q.prototype)).constructor = rn, rn.prototype.isMeshLambertMaterial = !0, rn.prototype.copy = function(t) {
		return Q.prototype.copy.call(this, t), this.color.copy(t.color), this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.specularMap = t.specularMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.combine = t.combine, this.reflectivity = t.reflectivity, this.refractionRatio = t.refractionRatio, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.skinning = t.skinning, this.morphTargets = t.morphTargets, this.morphNormals = t.morphNormals, this
	}, (an.prototype = Object.create(Ae.prototype)).constructor = an, an.prototype.isLineDashedMaterial = !0, an.prototype.copy = function(t) {
		return Ae.prototype.copy.call(this, t), this.scale = t.scale, this.dashSize = t.dashSize, this.gapSize = t.gapSize, this
	};
	var eo = Object.freeze({
			ShadowMaterial: Je,
			SpriteMaterial: Me,
			RawShaderMaterial: Ke,
			ShaderMaterial: It,
			PointsMaterial: Ie,
			MeshPhysicalMaterial: $e,
			MeshStandardMaterial: Qe,
			MeshPhongMaterial: tn,
			MeshToonMaterial: en,
			MeshNormalMaterial: nn,
			MeshLambertMaterial: rn,
			MeshDepthMaterial: $,
			MeshDistanceMaterial: tt,
			Mal: Pt,
			LineDashedMaterial: an,
			LineBasicMaterial: Ae,
			Material: Q
		}),
		no = {
			enabled: !1,
			files: {},
			add: function(t, e) {
				!1 !== this.enabled && (this.files[t] = e)
			},
			get: function(t) {
				if(!1 !== this.enabled) return this.files[t]
			},
			remove: function(t) {
				delete this.files[t]
			},
			clear: function() {
				this.files = {}
			}
		},
		io = new on,
		ro = {};
	Object.assign(sn.prototype, {
		load: function(t, e, n, i) {
			void 0 === t && (t = ""), void 0 !== this.path && (t = this.path + t), t = this.manager.resolveURL(t);
			var r = this,
				a = no.get(t);
			if(void 0 !== a) return r.manager.itemStart(t), setTimeout(function() {
				e && e(a), r.manager.itemEnd(t)
			}, 0), a;
			if(void 0 === ro[t]) {
				var o = /^data:(.*?)(;base64)?,(.*)$/,
					s = t.match(o);
				if(s) {
					var l = s[1],
						c = !!s[2],
						h = s[3];
					h = window.decodeURIComponent(h), c && (h = window.atob(h));
					try {
						var u, f = (this.responseType || "").toLowerCase();
						switch(f) {
							case "arraybuffer":
							case "blob":
								for(var p = new Uint8Array(h.length), d = 0; d < h.length; d++) p[d] = h.charCodeAt(d);
								u = "blob" === f ? new Blob([p.buffer], {
									type: l
								}) : p.buffer;
								break;
							case "document":
								var m = new DOMParser;
								u = m.parseFromString(h, l);
								break;
							case "json":
								u = JSON.parse(h);
								break;
							default:
								u = h
						}
						window.setTimeout(function() {
							e && e(u), r.manager.itemEnd(t)
						}, 0)
					} catch(e) {
						window.setTimeout(function() {
							i && i(e), r.manager.itemEnd(t), r.manager.itemError(t)
						}, 0)
					}
				} else {
					ro[t] = [], ro[t].push({
						onLoad: e,
						onProgress: n,
						onError: i
					});
					var g = new XMLHttpRequest;
					g.open("GET", t, !0), g.addEventListener("load", function(e) {
						var n = e.target.response;
						no.add(t, n);
						var i = ro[t];
						if(delete ro[t], 200 === this.status) {
							for(var a = 0, o = i.length; a < o; a++)(s = i[a]).onLoad && s.onLoad(n);
							r.manager.itemEnd(t)
						} else if(0 === this.status) {
							for(var a = 0, o = i.length; a < o; a++)(s = i[a]).onLoad && s.onLoad(n);
							r.manager.itemEnd(t)
						} else {
							for(var a = 0, o = i.length; a < o; a++) {
								var s = i[a];
								s.onError && s.onError(e)
							}
							r.manager.itemEnd(t), r.manager.itemError(t)
						}
					}, !1), g.addEventListener("progress", function(e) {
						for(var n = ro[t], i = 0, r = n.length; i < r; i++) {
							var a = n[i];
							a.onProgress && a.onProgress(e)
						}
					}, !1), g.addEventListener("error", function(e) {
						var n = ro[t];
						delete ro[t];
						for(var i = 0, a = n.length; i < a; i++) {
							var o = n[i];
							o.onError && o.onError(e)
						}
						r.manager.itemEnd(t), r.manager.itemError(t)
					}, !1), void 0 !== this.responseType && (g.responseType = this.responseType), void 0 !== this.withCredentials && (g.withCredentials = this.withCredentials), g.overrideMimeType && g.overrideMimeType(void 0 !== this.mimeType ? this.mimeType : "text/plain");
					for(var v in this.requestHeader) g.setRequestHeader(v, this.requestHeader[v]);
					g.send(null)
				}
				return r.manager.itemStart(t), g
			}
			ro[t].push({
				onLoad: e,
				onProgress: n,
				onError: i
			})
		},
		setPath: function(t) {
			return this.path = t, this
		},
		setResponseType: function(t) {
			return this.responseType = t, this
		},
		setWithCredentials: function(t) {
			return this.withCredentials = t, this
		},
		setMimeType: function(t) {
			return this.mimeType = t, this
		},
		setRequestHeader: function(t) {
			return this.requestHeader = t, this
		}
	}), Object.assign(ln.prototype, {
		load: function(t, e, n, i) {
			var r = this,
				a = [],
				o = new De;
			o.image = a;
			var s = new sn(this.manager);
			if(s.setPath(this.path), s.setResponseType("arraybuffer"), Array.isArray(t))
				for(var l = 0, c = 0, h = t.length; c < h; ++c) ! function(c) {
					s.load(t[c], function(t) {
						var n = r._parser(t, !0);
						a[c] = {
							width: n.width,
							height: n.height,
							format: n.format,
							mipmaps: n.mipmaps
						}, 6 === (l += 1) && (1 === n.mipmapCount && (o.minFilter = Hr), o.format = n.format, o.needsUpdate = !0, e && e(o))
					}, n, i)
				}(c);
			else s.load(t, function(t) {
				var n = r._parser(t, !0);
				if(n.isCubemap)
					for(var i = n.mipmaps.length / n.mipmapCount, s = 0; s < i; s++) {
						a[s] = {
							mipmaps: []
						};
						for(var l = 0; l < n.mipmapCount; l++) a[s].mipmaps.push(n.mipmaps[s * n.mipmapCount + l]), a[s].format = n.format, a[s].width = n.width, a[s].height = n.height
					} else o.image.width = n.width, o.image.height = n.height, o.mipmaps = n.mipmaps;
				1 === n.mipmapCount && (o.minFilter = Hr), o.format = n.format, o.needsUpdate = !0, e && e(o)
			}, n, i);
			return o
		},
		setPath: function(t) {
			return this.path = t, this
		}
	}), Object.assign(cn.prototype, {
		load: function(t, e, n, i) {
			var r = this,
				a = new u,
				o = new sn(this.manager);
			return o.setResponseType("arraybuffer"), o.load(t, function(t) {
				var n = r._parser(t);
				n && (void 0 !== n.image ? a.image = n.image : void 0 !== n.data && (a.image.width = n.width, a.image.height = n.height, a.image.data = n.data), a.wrapS = void 0 !== n.wrapS ? n.wrapS : Fr, a.wrapT = void 0 !== n.wrapT ? n.wrapT : Fr, a.magFilter = void 0 !== n.magFilter ? n.magFilter : Hr, a.minFilter = void 0 !== n.minFilter ? n.minFilter : Xr, a.anisotropy = void 0 !== n.anisotropy ? n.anisotropy : 1, void 0 !== n.format && (a.format = n.format), void 0 !== n.type && (a.type = n.type), void 0 !== n.mipmaps && (a.mipmaps = n.mipmaps), 1 === n.mipmapCount && (a.minFilter = Hr), a.needsUpdate = !0, e && e(a, n))
			}, n, i), a
		}
	}), Object.assign(hn.prototype, {
		crossOrigin: "Anonymous",
		load: function(t, e, n, i) {
			void 0 === t && (t = ""), void 0 !== this.path && (t = this.path + t), t = this.manager.resolveURL(t);
			var r = this,
				a = no.get(t);
			if(void 0 !== a) return r.manager.itemStart(t), setTimeout(function() {
				e && e(a), r.manager.itemEnd(t)
			}, 0), a;
			var o = document.createElementNS("http://www.w3.org/1999/xhtml", "img");
			return o.addEventListener("load", function() {
				no.add(t, this), e && e(this), r.manager.itemEnd(t)
			}, !1), o.addEventListener("error", function(e) {
				i && i(e), r.manager.itemEnd(t), r.manager.itemError(t)
			}, !1), "data:" !== t.substr(0, 5) && void 0 !== this.crossOrigin && (o.crossOrigin = this.crossOrigin), r.manager.itemStart(t), o.src = t, o
		},
		setCrossOrigin: function(t) {
			return this.crossOrigin = t, this
		},
		setPath: function(t) {
			return this.path = t, this
		}
	}), Object.assign(un.prototype, {
		crossOrigin: "Anonymous",
		load: function(t, e, n, i) {
			var r = new f,
				a = new hn(this.manager);
			a.setCrossOrigin(this.crossOrigin), a.setPath(this.path);
			for(var o = 0, s = 0; s < t.length; ++s) ! function(n) {
				a.load(t[n], function(t) {
					r.images[n] = t, 6 == ++o && (r.needsUpdate = !0, e && e(r))
				}, void 0, i)
			}(s);
			return r
		},
		setCrossOrigin: function(t) {
			return this.crossOrigin = t, this
		},
		setPath: function(t) {
			return this.path = t, this
		}
	}), Object.assign(fn.prototype, {
		crossOrigin: "Anonymous",
		load: function(t, e, n, i) {
			var r = new s,
				a = new hn(this.manager);
			return a.setCrossOrigin(this.crossOrigin), a.setPath(this.path), a.load(t, function(n) {
				r.image = n;
				var i = t.search(/\.(jpg|jpeg)$/) > 0 || 0 === t.search(/^data\:image\/jpeg/);
				r.format = i ? oa : sa, r.needsUpdate = !0, void 0 !== e && e(r)
			}, n, i), r
		},
		setCrossOrigin: function(t) {
			return this.crossOrigin = t, this
		},
		setPath: function(t) {
			return this.path = t, this
		}
	}), pn.prototype = Object.assign(Object.create(ct.prototype), {
		constructor: pn,
		isLight: !0,
		copy: function(t) {
			return ct.prototype.copy.call(this, t), this.color.copy(t.color), this.intensity = t.intensity, this
		},
		toJSON: function(t) {
			var e = ct.prototype.toJSON.call(this, t);
			return e.object.color = this.color.getHex(), e.object.intensity = this.intensity, void 0 !== this.groundColor && (e.object.groundColor = this.groundColor.getHex()), void 0 !== this.distance && (e.object.distance = this.distance), void 0 !== this.angle && (e.object.angle = this.angle), void 0 !== this.decay && (e.object.decay = this.decay), void 0 !== this.penumbra && (e.object.penumbra = this.penumbra), void 0 !== this.shadow && (e.object.shadow = this.shadow.toJSON()), e
		}
	}), dn.prototype = Object.assign(Object.create(pn.prototype), {
		constructor: dn,
		isHemisphereLight: !0,
		copy: function(t) {
			return pn.prototype.copy.call(this, t), this.groundColor.copy(t.groundColor), this
		}
	}), Object.assign(mn.prototype, {
		copy: function(t) {
			return this.camera = t.camera.clone(), this.bias = t.bias, this.radius = t.radius, this.mapSize.copy(t.mapSize), this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		toJSON: function() {
			var t = {};
			return 0 !== this.bias && (t.bias = this.bias), 1 !== this.radius && (t.radius = this.radius), 512 === this.mapSize.x && 512 === this.mapSize.y || (t.mapSize = this.mapSize.toArray()), t.camera = this.camera.toJSON(!1).object, delete t.camera.matrix, t
		}
	}), gn.prototype = Object.assign(Object.create(mn.prototype), {
		constructor: gn,
		isSpotLightShadow: !0,
		update: function(t) {
			var e = this.camera,
				n = 2 * Oa.RAD2DEG * t.angle,
				i = this.mapSize.width / this.mapSize.height,
				r = t.distance || e.far;
			n === e.fov && i === e.aspect && r === e.far || (e.fov = n, e.aspect = i, e.far = r, e.ux())
		}
	}), vn.prototype = Object.assign(Object.create(pn.prototype), {
		constructor: vn,
		isSpotLight: !0,
		copy: function(t) {
			return pn.prototype.copy.call(this, t), this.distance = t.distance, this.angle = t.angle, this.penumbra = t.penumbra, this.decay = t.decay, this.target = t.target.clone(), this.shadow = t.shadow.clone(), this
		}
	}), _n.prototype = Object.assign(Object.create(pn.prototype), {
		constructor: _n,
		isPointLight: !0,
		copy: function(t) {
			return pn.prototype.copy.call(this, t), this.distance = t.distance, this.decay = t.decay, this.shadow = t.shadow.clone(), this
		}
	}), yn.prototype = Object.assign(Object.create(mn.prototype), {
		constructor: yn
	}), xn.prototype = Object.assign(Object.create(pn.prototype), {
		constructor: xn,
		isDt: !0,
		copy: function(t) {
			return pn.prototype.copy.call(this, t), this.target = t.target.clone(), this.shadow = t.shadow.clone(), this
		}
	}), bn.prototype = Object.assign(Object.create(pn.prototype), {
		constructor: bn,
		isAmbientLight: !0
	}), wn.prototype = Object.assign(Object.create(pn.prototype), {
		constructor: wn,
		isRectAreaLight: !0,
		copy: function(t) {
			return pn.prototype.copy.call(this, t), this.width = t.width, this.height = t.height, this
		},
		toJSON: function(t) {
			var e = pn.prototype.toJSON.call(this, t);
			return e.object.width = this.width, e.object.height = this.height, e
		}
	}), Object.assign(Mn.prototype, {
		evaluate: function(t) {
			var e = this.parameterPositions,
				n = this._cachedIndex,
				i = e[n],
				r = e[n - 1];
			t: {
				e: {
					var a;n: {
						i: if(!(t < i)) {
							for(s = n + 2;;) {
								if(void 0 === i) {
									if(t < r) break i;
									return n = e.length, this._cachedIndex = n, this.afternd_(n - 1, t, r)
								}
								if(n === s) break;
								if(r = i, i = e[++n], t < i) break e
							}
							a = e.length;
							break n
						} {
							if(t >= r) break t;
							var o = e[1];
							t < o && (n = 2, r = o);
							for(var s = n - 2;;) {
								if(void 0 === r) return this._cachedIndex = 0, this.beforeStart_(0, t, i);
								if(n === s) break;
								if(i = r, r = e[--n - 1], t >= r) break e
							}
							a = n, n = 0
						}
					}
					for(; n < a;) {
						var l = n + a >>> 1;
						t < e[l] ? a = l : n = l + 1
					}
					if(i = e[n], void 0 === (r = e[n - 1])) return this._cachedIndex = 0, this.beforeStart_(0, t, i);
					if(void 0 === i) return n = e.length, this._cachedIndex = n, this.afternd_(n - 1, r, t)
				}
				this._cachedIndex = n,
				this.intervalChanged_(n, r, i)
			}
			return this.interpolate_(n, r, t, i)
		},
		settings: null,
		DefaultSettings_: {},
		getSettings_: function() {
			return this.settings || this.DefaultSettings_
		},
		copySampleValue_: function(t) {
			for(var e = this.resultBuffer, n = this.sampleValues, i = this.valueSize, r = t * i, a = 0; a !== i; ++a) e[a] = n[r + a];
			return e
		},
		interpolate_: function() {},
		intervalChanged_: function() {}
	}), Object.assign(Mn.prototype, {
		beforeStart_: Mn.prototype.copySampleValue_,
		afternd_: Mn.prototype.copySampleValue_
	}), Sn.prototype = Object.assign(Object.create(Mn.prototype), {
		constructor: Sn,
		interpolate_: function(t, e, n, i) {
			for(var a = this.resultBuffer, o = this.sampleValues, s = this.valueSize, l = t * s, c = (n - e) / (i - e), h = l + s; l !== h; l += 4) r.slerpFlat(a, 0, o, l - s, o, l, c);
			return a
		}
	}), Gn.prototype = Object.assign(Object.create(Cn.prototype), {
		constructor: Gn,
		ValueTypeName: "quaternion",
		DefaultInterpolation: 2301,
		InterpolantFactoryMethodLinear: function(t) {
			return new Sn(this.times, this.values, this.getValueSize(), t)
		},
		InterpolantFactoryMethodSmooth: void 0
	}), En.prototype = Object.assign(Object.create(Cn.prototype), {
		constructor: En,
		ValueTypeName: "number"
	}), Tn.prototype = Object.assign(Object.create(Mn.prototype), {
		constructor: Tn,
		DefaultSettings_: {
			endingStart: 2400,
			endingEnd: 2400
		},
		intervalChanged_: function(t, e, n) {
			var i = this.parameterPositions,
				r = t - 2,
				a = t + 1,
				o = i[r],
				s = i[a];
			if(void 0 === o) switch(this.getSettings_().endingStart) {
				case 2401:
					r = t, o = 2 * e - n;
					break;
				case 2402:
					o = e + i[r = i.length - 2] - i[r + 1];
					break;
				default:
					r = t, o = n
			}
			if(void 0 === s) switch(this.getSettings_().endingEnd) {
				case 2401:
					a = t, s = 2 * n - e;
					break;
				case 2402:
					a = 1, s = n + i[1] - i[0];
					break;
				default:
					a = t - 1, s = e
			}
			var l = .5 * (n - e),
				c = this.valueSize;
			this._weightPrev = l / (e - o), this._weightNext = l / (s - n), this._offsetPrev = r * c, this._offsetNext = a * c
		},
		interpolate_: function(t, e, n, i) {
			for(var r = this.resultBuffer, a = this.sampleValues, o = this.valueSize, s = t * o, l = s - o, c = this._offsetPrev, h = this._offsetNext, u = this._weightPrev, f = this._weightNext, p = (n - e) / (i - e), d = p * p, m = d * p, g = -u * m + 2 * u * d - u * p, v = (1 + u) * m + (-1.5 - 2 * u) * d + (-.5 + u) * p + 1, _ = (-1 - f) * m + (1.5 + f) * d + .5 * p, y = f * m - f * d, x = 0; x !== o; ++x) r[x] = g * a[c + x] + v * a[l + x] + _ * a[s + x] + y * a[h + x];
			return r
		}
	}), An.prototype = Object.assign(Object.create(Mn.prototype), {
		constructor: An,
		interpolate_: function(t, e, n, i) {
			for(var r = this.resultBuffer, a = this.sampleValues, o = this.valueSize, s = t * o, l = s - o, c = (n - e) / (i - e), h = 1 - c, u = 0; u !== o; ++u) r[u] = a[l + u] * h + a[s + u] * c;
			return r
		}
	}), Ln.prototype = Object.assign(Object.create(Mn.prototype), {
		constructor: Ln,
		interpolate_: function(t) {
			return this.copySampleValue_(t - 1)
		}
	});
	var ao = {
		arraySlice: function(t, e, n) {
			return ao.isTypedArray(t) ? new t.constructor(t.subarray(e, void 0 !== n ? n : t.length)) : t.slice(e, n)
		},
		convertArray: function(t, e, n) {
			return !t || !n && t.constructor === e ? t : "number" == typeof e.BYTES_PER_ELEMENT ? new e(t) : Array.prototype.slice.call(t)
		},
		isTypedArray: function(t) {
			return ArrayBuffer.isView(t) && !(t instanceof DataView)
		},
		getKeyframeOrder: function(t) {
			for(var e = t.length, n = new Array(e), i = 0; i !== e; ++i) n[i] = i;
			return n.sort(function(e, n) {
				return t[e] - t[n]
			}), n
		},
		sortedArray: function(t, e, n) {
			for(var i = t.length, r = new t.constructor(i), a = 0, o = 0; o !== i; ++a)
				for(var s = n[a] * e, l = 0; l !== e; ++l) r[o++] = t[s + l];
			return r
		},
		flattenJSON: function(t, e, n, i) {
			for(var r = 1, a = t[0]; void 0 !== a && void 0 === a[i];) a = t[r++];
			if(void 0 !== a) {
				var o = a[i];
				if(void 0 !== o)
					if(Array.isArray(o))
						do {
							void 0 !== (o = a[i]) && (e.push(a.time), n.push.apply(n, o)), a = t[r++]
						} while (void 0 !== a);
					else if(void 0 !== o.toArray)
					do {
						void 0 !== (o = a[i]) && (e.push(a.time), o.toArray(n, n.length)), a = t[r++]
					} while (void 0 !== a);
				else
					do {
						void 0 !== (o = a[i]) && (e.push(a.time), n.push(o)), a = t[r++]
					} while (void 0 !== a)
			}
		}
	};
	Object.assign(Cn, {
		parse: function(t) {
			var e = Cn._getTrackTypeForValueTypeName(t.type);
			if(void 0 === t.times) {
				var n = [],
					i = [];
				ao.flattenJSON(t.keys, n, i, "value"), t.times = n, t.values = i
			}
			return void 0 !== e.parse ? e.parse(t) : new e(t.name, t.times, t.values, t.interpolation)
		},
		toJSON: function(t) {
			var e, n = t.constructor;
			if(void 0 !== n.toJSON) e = n.toJSON(t);
			else {
				e = {
					name: t.name,
					times: ao.convertArray(t.times, Array),
					values: ao.convertArray(t.values, Array)
				};
				var i = t.getInterpolation();
				i !== t.DefaultInterpolation && (e.interpolation = i)
			}
			return e.type = t.ValueTypeName, e
		},
		_getTrackTypeForValueTypeName: function(t) {
			switch(t.toLowerCase()) {
				case "scalar":
				case "double":
				case "float":
				case "number":
				case "integer":
					return En;
				case "vector":
				case "vector2":
				case "vector3":
				case "vector4":
					return Pn;
				case "quaternion":
					return Gn
			}
		}
	}), Object.assign(Cn.prototype, {
		constructor: Cn,
		TimeBufferType: Float32Array,
		ValueBufferType: Float32Array,
		DefaultInterpolation: 2301,
		InterpolantFactoryMethodDiscrete: function(t) {
			return new Ln(this.times, this.values, this.getValueSize(), t)
		},
		InterpolantFactoryMethodLinear: function(t) {
			return new An(this.times, this.values, this.getValueSize(), t)
		},
		InterpolantFactoryMethodSmooth: function(t) {
			return new Tn(this.times, this.values, this.getValueSize(), t)
		},
		setInterpolation: function(t) {
			var e;
			switch(t) {
				case 2300:
					e = this.InterpolantFactoryMethodDiscrete;
					break;
				case 2301:
					e = this.InterpolantFactoryMethodLinear;
					break;
				case 2302:
					e = this.InterpolantFactoryMethodSmooth
			}
			if(void 0 !== e) this.createInterpolant = e;
			else {
				this.ValueTypeName, this.name;
				void 0 === this.createInterpolant && t !== this.DefaultInterpolation && this.setInterpolation(this.DefaultInterpolation)
			}
		},
		getInterpolation: function() {
			switch(this.createInterpolant) {
				case this.InterpolantFactoryMethodDiscrete:
					return 2300;
				case this.InterpolantFactoryMethodLinear:
					return 2301;
				case this.InterpolantFactoryMethodSmooth:
					return 2302
			}
		},
		getValueSize: function() {
			return this.values.length / this.times.length
		},
		shift: function(t) {
			if(0 !== t)
				for(var e = this.times, n = 0, i = e.length; n !== i; ++n) e[n] += t;
			return this
		},
		scale: function(t) {
			if(1 !== t)
				for(var e = this.times, n = 0, i = e.length; n !== i; ++n) e[n] *= t;
			return this
		},
		trim: function(t, e) {
			for(var n = this.times, i = n.length, r = 0, a = i - 1; r !== i && n[r] < t;) ++r;
			for(; - 1 !== a && n[a] > e;) --a;
			if(++a, 0 !== r || a !== i) {
				r >= a && (a = Math.max(a, 1), r = a - 1);
				var o = this.getValueSize();
				this.times = ao.arraySlice(n, r, a), this.values = ao.arraySlice(this.values, r * o, a * o)
			}
			return this
		},
		validate: function() {
			var t = !0,
				e = this.getValueSize();
			e - Math.floor(e) != 0 && (t = !1);
			var n = this.times,
				i = this.values,
				r = n.length;
			0 === r && (t = !1);
			for(var a = null, o = 0; o !== r; o++) {
				var s = n[o];
				if("number" == typeof s && isNaN(s)) {
					t = !1;
					break
				}
				if(null !== a && a > s) {
					t = !1;
					break
				}
				a = s
			}
			if(void 0 !== i && ao.isTypedArray(i))
				for(var o = 0, l = i.length; o !== l; ++o) {
					var c = i[o];
					if(isNaN(c)) {
						t = !1;
						break
					}
				}
			return t
		},
		optimize: function() {
			for(var t = this.times, e = this.values, n = this.getValueSize(), i = 2302 === this.getInterpolation(), r = 1, a = t.length - 1, o = 1; o < a; ++o) {
				var s = !1,
					l = t[o];
				if(l !== t[o + 1] && (1 !== o || l !== l[0]))
					if(i) s = !0;
					else
						for(var c = o * n, h = c - n, u = c + n, f = 0; f !== n; ++f) {
							var p = e[c + f];
							if(p !== e[h + f] || p !== e[u + f]) {
								s = !0;
								break
							}
						}
				if(s) {
					if(o !== r) {
						t[r] = t[o];
						for(var d = o * n, m = r * n, f = 0; f !== n; ++f) e[m + f] = e[d + f]
					}++r
				}
			}
			if(a > 0) {
				t[r] = t[a];
				for(var d = a * n, m = r * n, f = 0; f !== n; ++f) e[m + f] = e[d + f];
				++r
			}
			return r !== t.length && (this.times = ao.arraySlice(t, 0, r), this.values = ao.arraySlice(e, 0, r * n)), this
		}
	}), Pn.prototype = Object.assign(Object.create(Cn.prototype), {
		constructor: Pn,
		ValueTypeName: "vector"
	}), Object.assign(In, {
		parse: function(t) {
			for(var e = [], n = t.tracks, i = 1 / (t.fps || 1), r = 0, a = n.length; r !== a; ++r) e.push(Cn.parse(n[r]).scale(i));
			return new In(t.name, t.duration, e)
		},
		toJSON: function(t) {
			for(var e = [], n = t.tracks, i = {
					name: t.name,
					duration: t.duration,
					tracks: e
				}, r = 0, a = n.length; r !== a; ++r) e.push(Cn.toJSON(n[r]));
			return i
		},
		CreateFromMorphTargetSequence: function(t, e, n, i) {
			for(var r = e.length, a = [], o = 0; o < r; o++) {
				var s = [],
					l = [];
				s.push((o + r - 1) % r, o, (o + 1) % r), l.push(0, 1, 0);
				var c = ao.getKeyframeOrder(s);
				s = ao.sortedArray(s, 1, c), l = ao.sortedArray(l, 1, c), i || 0 !== s[0] || (s.push(r), l.push(l[0])), a.push(new En(".morphTargetInfluences[" + e[o].name + "]", s, l).scale(1 / n))
			}
			return new In(t, -1, a)
		},
		findByName: function(t, e) {
			var n = t;
			if(!Array.isArray(t)) {
				var i = t;
				n = i.geometry && i.geometry.animations || i.animations
			}
			for(var r = 0; r < n.length; r++)
				if(n[r].name === e) return n[r];
			return null
		},
		CreateClipsFromMorphTargetSequences: function(t, e, n) {
			for(var i = {}, r = /^([\w-]*?)([\d]+)$/, a = 0, o = t.length; a < o; a++) {
				var s = t[a],
					l = s.name.match(r);
				if(l && l.length > 1) {
					var c = i[u = l[1]];
					c || (i[u] = c = []), c.push(s)
				}
			}
			var h = [];
			for(var u in i) h.push(In.CreateFromMorphTargetSequence(u, i[u], e, n));
			return h
		},
		parseAnimation: function(t, e) {
			if(!t) return null;
			for(var n = function(t, e, n, i, r) {
					if(0 !== n.length) {
						var a = [],
							o = [];
						ao.flattenJSON(n, a, o, i), 0 !== a.length && r.push(new t(e, a, o))
					}
				}, i = [], r = t.name || "default", a = t.length || -1, o = t.fps || 30, s = t.hierarchy || [], l = 0; l < s.length; l++) {
				var c = s[l].keys;
				if(c && 0 !== c.length)
					if(c[0].morphTargets) {
						for(var h = {}, u = 0; u < c.length; u++)
							if(c[u].morphTargets)
								for(m = 0; m < c[u].morphTargets.length; m++) h[c[u].morphTargets[m]] = -1;
						for(var f in h) {
							for(var p = [], d = [], m = 0; m !== c[u].morphTargets.length; ++m) {
								var g = c[u];
								p.push(g.time), d.push(g.morphTarget === f ? 1 : 0)
							}
							i.push(new En(".morphTargetInfluence[" + f + "]", p, d))
						}
						a = h.length * (o || 1)
					} else {
						var v = ".bones[" + e[l].name + "]";
						n(Pn, v + ".position", c, "pos", i), n(Gn, v + ".quaternion", c, "rot", i), n(Pn, v + ".scale", c, "scl", i)
					}
			}
			return 0 === i.length ? null : new In(r, a, i)
		}
	}), Object.assign(In.prototype, {
		resetDuration: function() {
			for(var t = 0, e = 0, n = this.tracks.length; e !== n; ++e) {
				var i = this.tracks[e];
				t = Math.max(t, i.times[i.times.length - 1])
			}
			this.duration = t
		},
		trim: function() {
			for(var t = 0; t < this.tracks.length; t++) this.tracks[t].trim(0, this.duration);
			return this
		},
		optimize: function() {
			for(var t = 0; t < this.tracks.length; t++) this.tracks[t].optimize();
			return this
		}
	}), Object.assign(Rn.prototype, {
		load: function(t, e, n, i) {
			var r = this;
			new sn(r.manager).load(t, function(t) {
				e(r.parse(JSON.parse(t)))
			}, n, i)
		},
		setTextures: function(t) {
			this.textures = t
		},
		parse: function(t) {
			function e(t) {
				return i[t], i[t]
			}
			var i = this.textures,
				r = new eo[t.type];
			if(void 0 !== t.uuid && (r.uuid = t.uuid), void 0 !== t.name && (r.name = t.name), void 0 !== t.color && r.color.setHex(t.color), void 0 !== t.roughness && (r.roughness = t.roughness), void 0 !== t.metalness && (r.metalness = t.metalness), void 0 !== t.emissive && r.emissive.setHex(t.emissive), void 0 !== t.specular && r.specular.setHex(t.specular), void 0 !== t.shininess && (r.shininess = t.shininess), void 0 !== t.clearCoat && (r.clearCoat = t.clearCoat), void 0 !== t.clearCoatRoughness && (r.clearCoatRoughness = t.clearCoatRoughness), void 0 !== t.uniforms && (r.uniforms = t.uniforms), void 0 !== t.vertexShader && (r.vertexShader = t.vertexShader), void 0 !== t.fragmentShader && (r.fragmentShader = t.fragmentShader), void 0 !== t.vertexColors && (r.vertexColors = t.vertexColors), void 0 !== t.fog && (r.fog = t.fog), void 0 !== t.flatShading && (r.flatShading = t.flatShading), void 0 !== t.blending && (r.blending = t.blending), void 0 !== t.side && (r.side = t.side), void 0 !== t.opacity && (r.opacity = t.opacity), void 0 !== t.transparent && (r.transparent = t.transparent), void 0 !== t.alphaTest && (r.alphaTest = t.alphaTest), void 0 !== t.depthTest && (r.depthTest = t.depthTest), void 0 !== t.depthWrite && (r.depthWrite = t.depthWrite), void 0 !== t.colorWrite && (r.colorWrite = t.colorWrite), void 0 !== t.wireframe && (r.wireframe = t.wireframe), void 0 !== t.wireframeLinewidth && (r.wireframeLinewidth = t.wireframeLinewidth), void 0 !== t.wireframeLinecap && (r.wireframeLinecap = t.wireframeLinecap), void 0 !== t.wireframeLinejoin && (r.wireframeLinejoin = t.wireframeLinejoin), void 0 !== t.rotation && (r.rotation = t.rotation), 1 !== t.linewidth && (r.linewidth = t.linewidth), void 0 !== t.dashSize && (r.dashSize = t.dashSize), void 0 !== t.gapSize && (r.gapSize = t.gapSize), void 0 !== t.scale && (r.scale = t.scale), void 0 !== t.skinning && (r.skinning = t.skinning), void 0 !== t.morphTargets && (r.morphTargets = t.morphTargets), void 0 !== t.dithering && (r.dithering = t.dithering), void 0 !== t.visible && (r.visible = t.visible), void 0 !== t.userData && (r.userData = t.userData), void 0 !== t.shading && (r.flatShading = 1 === t.shading), void 0 !== t.size && (r.size = t.size), void 0 !== t.sizeAttenuation && (r.sizeAttenuation = t.sizeAttenuation), void 0 !== t.map && (r.map = e(t.map)), void 0 !== t.alphaMap && (r.alphaMap = e(t.alphaMap), r.transparent = !0), void 0 !== t.bumpMap && (r.bumpMap = e(t.bumpMap)), void 0 !== t.bumpScale && (r.bumpScale = t.bumpScale), void 0 !== t.normalMap && (r.normalMap = e(t.normalMap)), void 0 !== t.normalScale) {
				var a = t.normalScale;
				!1 === Array.isArray(a) && (a = [a, a]), r.normalScale = (new n).fromArray(a)
			}
			return void 0 !== t.displacementMap && (r.displacementMap = e(t.displacementMap)), void 0 !== t.displacementScale && (r.displacementScale = t.displacementScale), void 0 !== t.displacementBias && (r.displacementBias = t.displacementBias), void 0 !== t.roughnessMap && (r.roughnessMap = e(t.roughnessMap)), void 0 !== t.metalnessMap && (r.metalnessMap = e(t.metalnessMap)), void 0 !== t.emissiveMap && (r.emissiveMap = e(t.emissiveMap)), void 0 !== t.emissiveIntensity && (r.emissiveIntensity = t.emissiveIntensity), void 0 !== t.specularMap && (r.specularMap = e(t.specularMap)), void 0 !== t.envMap && (r.envMap = e(t.envMap)), void 0 !== t.reflectivity && (r.reflectivity = t.reflectivity), void 0 !== t.lightMap && (r.lightMap = e(t.lightMap)), void 0 !== t.lightMapIntensity && (r.lightMapIntensity = t.lightMapIntensity), void 0 !== t.aoMap && (r.aoMap = e(t.aoMap)), void 0 !== t.aoMapIntensity && (r.aoMapIntensity = t.aoMapIntensity), void 0 !== t.gradientMap && (r.gradientMap = e(t.gradientMap)), r
		}
	}), Object.assign(On.prototype, {
		load: function(t, e, n, i) {
			var r = this;
			new sn(r.manager).load(t, function(t) {
				e(r.parse(JSON.parse(t)))
			}, n, i)
		},
		parse: function(t) {
			var e = new Et,
				n = t.data.index;
			if(void 0 !== n) {
				s = new oo[n.type](n.array);
				e.setIndex(new dt(s, 1))
			}
			var i = t.data.attributes;
			for(var r in i) {
				var o = i[r],
					s = new oo[o.type](o.array);
				e.addAttribute(r, new dt(s, o.itemSize, o.normalized))
			}
			var l = t.data.groups || t.data.drawcalls || t.data.offsets;
			if(void 0 !== l)
				for(var c = 0, h = l.length; c !== h; ++c) {
					var u = l[c];
					e.addGroup(u.start, u.count, u.materialIndex)
				}
			var f = t.data.boundingSphere;
			if(void 0 !== f) {
				var p = new a;
				void 0 !== f.center && p.fromArray(f.center), e.boundingSphere = new nt(p, f.radius)
			}
			return e
		}
	});
	var oo = {
		Int8Array: Int8Array,
		Uint8Array: Uint8Array,
		Uint8ClampedArray: "undefined" != typeof Uint8ClampedArray ? Uint8ClampedArray : Uint8Array,
		Int16Array: Int16Array,
		Uint16Array: Uint16Array,
		Int32Array: Int32Array,
		Uint32Array: Uint32Array,
		Float32Array: Float32Array,
		Float64Array: Float64Array
	};
	Nn.Handlers = {
		handlers: [],
		add: function(t, e) {
			this.handlers.push(t, e)
		},
		get: function(t) {
			for(var e = this.handlers, n = 0, i = e.length; n < i; n += 2) {
				var r = e[n],
					a = e[n + 1];
				if(r.test(t)) return a
			}
			return null
		}
	}, Object.assign(Nn.prototype, {
		crossOrigin: void 0,
		extractUrlBase: function(t) {
			var e = t.split("/");
			return 1 === e.length ? "./" : (e.pop(), e.join("/") + "/")
		},
		initMaterials: function(t, e, n) {
			for(var i = [], r = 0; r < t.length; ++r) i[r] = this.createMaterial(t[r], e, n);
			return i
		},
		createMaterial: function() {
			var t = {
					NoBlending: Yi,
					NormalBlending: qi,
					AdditiveBlending: Zi,
					SubtractiveBlending: Ji,
					MultiplyBlending: Ki,
					CustomBlending: Qi
				},
				e = new Y,
				n = new fn,
				i = new Rn;
			return function(r, a, o) {
				function s(t, e, i, r, s) {
					var c, h = a + t,
						u = Nn.Handlers.get(h);
					null !== u ? c = u.load(h) : (n.setCrossOrigin(o), c = n.load(h)), void 0 !== e && (c.repeat.fromArray(e), 1 !== e[0] && (c.wrapS = Ur), 1 !== e[1] && (c.wrapT = Ur)), void 0 !== i && c.offset.fromArray(i), void 0 !== r && ("repeat" === r[0] && (c.wrapS = Ur), "mirror" === r[0] && (c.wrapS = kr), "repeat" === r[1] && (c.wrapT = Ur), "mirror" === r[1] && (c.wrapT = kr)), void 0 !== s && (c.anisotropy = s);
					var f = Oa.generateUUID();
					return l[f] = c, f
				}
				var l = {},
					c = {
						uuid: Oa.generateUUID(),
						type: "MeshLambertMaterial"
					};
				for(var h in r) {
					var u = r[h];
					switch(h) {
						case "DbgColor":
						case "DbgIndex":
						case "opticalDensity":
						case "illumination":
							break;
						case "DbgName":
							c.name = u;
							break;
						case "blending":
							c.blending = t[u];
							break;
						case "colorAmbient":
						case "mapAmbient":
							break;
						case "colorDiffuse":
							c.color = e.fromArray(u).getHex();
							break;
						case "colorSpecular":
							c.specular = e.fromArray(u).getHex();
							break;
						case "colorEmissive":
							c.emissive = e.fromArray(u).getHex();
							break;
						case "specularCoef":
							c.shininess = u;
							break;
						case "shading":
							"basic" === u.toLowerCase() && (c.type = "Mal"), "phong" === u.toLowerCase() && (c.type = "MeshPhongMaterial"), "standard" === u.toLowerCase() && (c.type = "MeshStandardMaterial");
							break;
						case "mapDiffuse":
							c.map = s(u, r.mapDiffuseRepeat, r.mapDiffuseOffset, r.mapDiffuseWrap, r.mapDiffuseAnisotropy);
							break;
						case "mapDiffuseRepeat":
						case "mapDiffuseOffset":
						case "mapDiffuseWrap":
						case "mapDiffuseAnisotropy":
							break;
						case "mapEmissive":
							c.emissiveMap = s(u, r.mapEmissiveRepeat, r.mapEmissiveOffset, r.mapEmissiveWrap, r.mapEmissiveAnisotropy);
							break;
						case "mapEmissiveRepeat":
						case "mapEmissiveOffset":
						case "mapEmissiveWrap":
						case "mapEmissiveAnisotropy":
							break;
						case "mapLight":
							c.lightMap = s(u, r.mapLightRepeat, r.mapLightOffset, r.mapLightWrap, r.mapLightAnisotropy);
							break;
						case "mapLightRepeat":
						case "mapLightOffset":
						case "mapLightWrap":
						case "mapLightAnisotropy":
							break;
						case "mapAO":
							c.aoMap = s(u, r.mapAORepeat, r.mapAOOffset, r.mapAOWrap, r.mapAOAnisotropy);
							break;
						case "mapAORepeat":
						case "mapAOOffset":
						case "mapAOWrap":
						case "mapAOAnisotropy":
							break;
						case "mapBump":
							c.bumpMap = s(u, r.mapBumpRepeat, r.mapBumpOffset, r.mapBumpWrap, r.mapBumpAnisotropy);
							break;
						case "mapBumpScale":
							c.bumpScale = u;
							break;
						case "mapBumpRepeat":
						case "mapBumpOffset":
						case "mapBumpWrap":
						case "mapBumpAnisotropy":
							break;
						case "mapNormal":
							c.normalMap = s(u, r.mapNormalRepeat, r.mapNormalOffset, r.mapNormalWrap, r.mapNormalAnisotropy);
							break;
						case "mapNormalFactor":
							c.normalScale = [u, u];
							break;
						case "mapNormalRepeat":
						case "mapNormalOffset":
						case "mapNormalWrap":
						case "mapNormalAnisotropy":
							break;
						case "mapSpecular":
							c.specularMap = s(u, r.mapSpecularRepeat, r.mapSpecularOffset, r.mapSpecularWrap, r.mapSpecularAnisotropy);
							break;
						case "mapSpecularRepeat":
						case "mapSpecularOffset":
						case "mapSpecularWrap":
						case "mapSpecularAnisotropy":
							break;
						case "mapMetalness":
							c.metalnessMap = s(u, r.mapMetalnessRepeat, r.mapMetalnessOffset, r.mapMetalnessWrap, r.mapMetalnessAnisotropy);
							break;
						case "mapMetalnessRepeat":
						case "mapMetalnessOffset":
						case "mapMetalnessWrap":
						case "mapMetalnessAnisotropy":
							break;
						case "mapRoughness":
							c.roughnessMap = s(u, r.mapRoughnessRepeat, r.mapRoughnessOffset, r.mapRoughnessWrap, r.mapRoughnessAnisotropy);
							break;
						case "mapRoughnessRepeat":
						case "mapRoughnessOffset":
						case "mapRoughnessWrap":
						case "mapRoughnessAnisotropy":
							break;
						case "mapAlpha":
							c.alphaMap = s(u, r.mapAlphaRepeat, r.mapAlphaOffset, r.mapAlphaWrap, r.mapAlphaAnisotropy);
							break;
						case "mapAlphaRepeat":
						case "mapAlphaOffset":
						case "mapAlphaWrap":
						case "mapAlphaAnisotropy":
							break;
						case "flipSided":
							c.side = ji;
							break;
						case "doubleSided":
							c.side = Hi;
							break;
						case "transparency":
							c.opacity = u;
							break;
						case "depthTest":
						case "depthWrite":
						case "colorWrite":
						case "opacity":
						case "reflectivity":
						case "transparent":
						case "visible":
						case "wireframe":
							c[h] = u;
							break;
						case "vertexColors":
							!0 === u && (c.vertexColors = Xi), "face" === u && (c.vertexColors = 1)
					}
				}
				return "Mal" === c.type && delete c.emissive, "MeshPhongMaterial" !== c.type && delete c.specular, c.opacity < 1 && (c.transparent = !0), i.setTextures(l), i.parse(c)
			}
		}()
	}), Object.assign(Dn.prototype, {
		load: function(t, e, n, i) {
			var r = this,
				a = this.texturePath && "string" == typeof this.texturePath ? this.texturePath : Nn.prototype.extractUrlBase(t),
				o = new sn(this.manager);
			o.setWithCredentials(this.withCredentials), o.load(t, function(t) {
				var n = JSON.parse(t),
					i = n.metadata;
				if(void 0 !== i) {
					var o = i.type;
					if(void 0 !== o) {
						if("object" === o.toLowerCase()) return;
						if("scene" === o.toLowerCase()) return
					}
				}
				var s = r.parse(n, a);
				e(s.geometry, s.materials)
			}, n, i)
		},
		setTexturePath: function(t) {
			this.texturePath = t
		},
		parse: function() {
			function t(t, e) {
				function i(t, e) {
					return t & 1 << e
				}
				var r, o, s, l, c, h, u, f, p, d, m, g, v, _, y, x, b, w, M, S, G, E, T, A, L, C = t.faces,
					P = t.vertices,
					I = t.normals,
					R = t.colors,
					O = t.scale,
					N = 0;
				if(void 0 !== t.uvs) {
					for(r = 0; r < t.uvs.length; r++) t.uvs[r].length && N++;
					for(r = 0; r < N; r++) e.faceVertexUvs[r] = []
				}
				for(l = 0, c = P.length; l < c;)(w = new a).x = P[l++] * O, w.y = P[l++] * O, w.z = P[l++] * O, e.vertices.push(w);
				for(l = 0, c = C.length; l < c;)
					if(d = C[l++], m = i(d, 0), g = i(d, 1), v = i(d, 3), _ = i(d, 4), y = i(d, 5), x = i(d, 6), b = i(d, 7), m) {
						if(S = new ft, S.a = C[l], S.b = C[l + 1], S.c = C[l + 3], G = new ft, G.a = C[l + 1], G.b = C[l + 2], G.c = C[l + 3], l += 4, g && (p = C[l++], S.materialIndex = p, G.materialIndex = p), s = e.faces.length, v)
							for(r = 0; r < N; r++)
								for(A = t.uvs[r], e.faceVertexUvs[r][s] = [], e.faceVertexUvs[r][s + 1] = [], o = 0; o < 4; o++) L = new n(A[2 * (f = C[l++])], A[2 * f + 1]), 2 !== o && e.faceVertexUvs[r][s].push(L), 0 !== o && e.faceVertexUvs[r][s + 1].push(L);
						if(_ && (u = 3 * C[l++], S.normal.set(I[u++], I[u++], I[u]), G.normal.copy(S.normal)), y)
							for(r = 0; r < 4; r++) u = 3 * C[l++], T = new a(I[u++], I[u++], I[u]), 2 !== r && S.vertexNormals.push(T), 0 !== r && G.vertexNormals.push(T);
						if(x && (E = R[h = C[l++]], S.color.setHex(E), G.color.setHex(E)), b)
							for(r = 0; r < 4; r++) E = R[h = C[l++]], 2 !== r && S.vertexColors.push(new Y(E)), 0 !== r && G.vertexColors.push(new Y(E));
						e.faces.push(S), e.faces.push(G)
					} else {
						if(M = new ft, M.a = C[l++], M.b = C[l++], M.c = C[l++], g && (p = C[l++], M.materialIndex = p), s = e.faces.length, v)
							for(r = 0; r < N; r++)
								for(A = t.uvs[r], e.faceVertexUvs[r][s] = [], o = 0; o < 3; o++) L = new n(A[2 * (f = C[l++])], A[2 * f + 1]), e.faceVertexUvs[r][s].push(L);
						if(_ && (u = 3 * C[l++], M.normal.set(I[u++], I[u++], I[u])), y)
							for(r = 0; r < 3; r++) u = 3 * C[l++], T = new a(I[u++], I[u++], I[u]), M.vertexNormals.push(T);
						if(x && (h = C[l++], M.color.setHex(R[h])), b)
							for(r = 0; r < 3; r++) h = C[l++], M.vertexColors.push(new Y(R[h]));
						e.faces.push(M)
					}
			}

			function e(t, e) {
				var n = void 0 !== t.influencesPerVertex ? t.influencesPerVertex : 2;
				if(t.skinWeights)
					for(var i = 0, r = t.skinWeights.length; i < r; i += n) {
						var a = t.skinWeights[i],
							o = n > 1 ? t.skinWeights[i + 1] : 0,
							s = n > 2 ? t.skinWeights[i + 2] : 0,
							c = n > 3 ? t.skinWeights[i + 3] : 0;
						e.skinWeights.push(new l(a, o, s, c))
					}
				if(t.skinIndices)
					for(var i = 0, r = t.skinIndices.length; i < r; i += n) {
						var h = t.skinIndices[i],
							u = n > 1 ? t.skinIndices[i + 1] : 0,
							f = n > 2 ? t.skinIndices[i + 2] : 0,
							p = n > 3 ? t.skinIndices[i + 3] : 0;
						e.skinIndices.push(new l(h, u, f, p))
					}
				e.bones = t.bones
			}

			function i(t, e) {
				var n = t.scale;
				if(void 0 !== t.morphTargets)
					for(var i = 0, r = t.morphTargets.length; i < r; i++) {
						e.morphTargets[i] = {}, e.morphTargets[i].name = t.morphTargets[i].name, e.morphTargets[i].vertices = [];
						for(var o = e.morphTargets[i].vertices, s = t.morphTargets[i].vertices, l = 0, c = s.length; l < c; l += 3) {
							var h = new a;
							h.x = s[l] * n, h.y = s[l + 1] * n, h.z = s[l + 2] * n, o.push(h)
						}
					}
				if(void 0 !== t.morphColors && t.morphColors.length > 0)
					for(var u = e.faces, f = t.morphColors[0].colors, i = 0, r = u.length; i < r; i++) u[i].color.fromArray(f, 3 * i)
			}

			function r(t, e) {
				var n = [],
					i = [];
				void 0 !== t.animation && i.push(t.animation), void 0 !== t.animations && (t.animations.length ? i = i.concat(t.animations) : i.push(t.animations));
				for(var r = 0; r < i.length; r++) {
					var a = In.parseAnimation(i[r], e.bones);
					a && n.push(a)
				}
				if(e.morphTargets) {
					var o = In.CreateClipsFromMorphTargetSequences(e.morphTargets, 10);
					n = n.concat(o)
				}
				n.length > 0 && (e.animations = n)
			}
			return function(n, a) {
				void 0 !== n.data && (n = n.data), void 0 !== n.scale ? n.scale = 1 / n.scale : n.scale = 1;
				var o = new pt;
				return t(n, o), e(n, o), i(n, o), r(n, o), o.computeFaceNormals(), o.computeBoundingSphere(), void 0 === n.materials || 0 === n.materials.length ? {
					geometry: o
				} : {
					geometry: o,
					materials: Nn.prototype.initMaterials(n.materials, a, this.crossOrigin)
				}
			}
		}()
	}), Object.assign(zn.prototype, {
		load: function(t, e, n, i) {
			"" === this.texturePath && (this.texturePath = t.substring(0, t.lastIndexOf("/") + 1));
			var r = this;
			new sn(r.manager).load(t, function(t) {
				var n = null;
				try {
					n = JSON.parse(t)
				} catch(t) {
					return void(void 0 !== i && i(t))
				}
				var a = n.metadata;
				void 0 !== a && void 0 !== a.type && "geometry" !== a.type.toLowerCase() && r.parse(n, e)
			}, n, i)
		},
		setTexturePath: function(t) {
			this.texturePath = t
		},
		setCrossOrigin: function(t) {
			this.crossOrigin = t
		},
		parse: function(t, e) {
			var n = this.parseGeometries(t.geometries),
				i = this.parseImages(t.images, function() {
					void 0 !== e && e(o)
				}),
				r = this.parseTextures(t.textures, i),
				a = this.parseMaterials(t.materials, r),
				o = this.parseObject(t.object, n, a);
			return t.animations && (o.animations = this.parseAnimations(t.animations)), void 0 !== t.images && 0 !== t.images.length || void 0 !== e && e(o), o
		},
		parseGeometries: function(t) {
			var e = {};
			if(void 0 !== t)
				for(var n = new Dn, i = new On, r = 0, a = t.length; r < a; r++) {
					var o, s = t[r];
					switch(s.type) {
						case "PlaneGeometry":
						case "PlaneBufferGeometry":
							o = new to[s.type](s.width, s.height, s.widthSegments, s.heightSegments);
							break;
						case "BoxGeometry":
						case "By":
						case "CubeGeometry":
							o = new to[s.type](s.width, s.height, s.depth, s.widthSegments, s.heightSegments, s.depthSegments);
							break;
						case "CircleGeometry":
						case "CircleBufferGeometry":
							o = new to[s.type](s.radius, s.segments, s.thetaStart, s.thetaLength);
							break;
						case "CylinderGeometry":
						case "CylinderBufferGeometry":
							o = new to[s.type](s.radiusTop, s.radiusBottom, s.height, s.radialSegments, s.heightSegments, s.openEnded, s.thetaStart, s.thetaLength);
							break;
						case "ConeGeometry":
						case "ConeBufferGeometry":
							o = new to[s.type](s.radius, s.height, s.radialSegments, s.heightSegments, s.openEnded, s.thetaStart, s.thetaLength);
							break;
						case "SphereGeometry":
						case "SphereBufferGeometry":
							o = new to[s.type](s.radius, s.widthSegments, s.heightSegments, s.phiStart, s.phiLength, s.thetaStart, s.thetaLength);
							break;
						case "BufferGeometry":
							o = i.parse(s);
							break;
						case "Geometry":
							o = n.parse(s, this.texturePath).geometry;
							break;
						default:
							continue
					}
					o.uuid = s.uuid, void 0 !== s.name && (o.name = s.name), e[s.uuid] = o
				}
			return e
		},
		parseMaterials: function(t, e) {
			var n = {};
			if(void 0 !== t) {
				var i = new Rn;
				i.setTextures(e);
				for(var r = 0, a = t.length; r < a; r++) {
					var o = t[r];
					if("MultiMaterial" === o.type) {
						for(var s = [], l = 0; l < o.materials.length; l++) s.push(i.parse(o.materials[l]));
						n[o.uuid] = s
					} else n[o.uuid] = i.parse(o)
				}
			}
			return n
		},
		parseAnimations: function(t) {
			for(var e = [], n = 0; n < t.length; n++) {
				var i = In.parse(t[n]);
				e.push(i)
			}
			return e
		},
		parseImages: function(t, e) {
			var n = this,
				i = {};
			if(void 0 !== t && t.length > 0) {
				var r = new hn(new on(e));
				r.setCrossOrigin(this.crossOrigin);
				for(var a = 0, o = t.length; a < o; a++) {
					var s = t[a],
						l = /^(\/\/)|([a-z]+:(\/\/)?)/i.test(s.url) ? s.url : n.texturePath + s.url;
					i[s.uuid] = function(t) {
						return n.manager.itemStart(t), r.load(t, function() {
							n.manager.itemEnd(t)
						}, void 0, function() {
							n.manager.itemEnd(t), n.manager.itemError(t)
						})
					}(l)
				}
			}
			return i
		},
		parseTextures: function(t, e) {
			function n(t, e) {
				return "number" == typeof t ? t : e[t]
			}
			var i = {};
			if(void 0 !== t)
				for(var r = 0, a = t.length; r < a; r++) {
					var o = t[r],
						l = new s(e[o.image]);
					l.needsUpdate = !0, l.uuid = o.uuid, void 0 !== o.name && (l.name = o.name), void 0 !== o.mapping && (l.mapping = n(o.mapping, so)), void 0 !== o.offset && l.offset.fromArray(o.offset), void 0 !== o.repeat && l.repeat.fromArray(o.repeat), void 0 !== o.center && l.center.fromArray(o.center), void 0 !== o.rotation && (l.rotation = o.rotation), void 0 !== o.wrap && (l.wrapS = n(o.wrap[0], lo), l.wrapT = n(o.wrap[1], lo)), void 0 !== o.minFilter && (l.minFilter = n(o.minFilter, co)), void 0 !== o.magFilter && (l.magFilter = n(o.magFilter, co)), void 0 !== o.anisotropy && (l.anisotropy = o.anisotropy), void 0 !== o.flipY && (l.flipY = o.flipY), i[o.uuid] = l
				}
			return i
		},
		parseObject: function() {
			var t = new i;
			return function(e, n, i) {
				function r(t) {
					return n[t]
				}

				function a(t) {
					if(void 0 !== t) {
						if(Array.isArray(t)) {
							for(var e = [], n = 0, r = t.length; n < r; n++) {
								var a = t[n];
								e.push(i[a])
							}
							return e
						}
						return i[t]
					}
				}
				var o;
				switch(e.type) {
					case "Scene":
						o = new be, void 0 !== e.background && Number.isInteger(e.background) && (o.background = new Y(e.background)), void 0 !== e.fog && "Fog" === e.fog.type && (o.fog = new xe(e.fog.color, e.fog.near, e.fog.far));
						break;
					case "Pa":
						o = new de(e.fov, e.aspect, e.near, e.far), void 0 !== e.focus && (o.focus = e.focus), void 0 !== e.zoom && (o.zoom = e.zoom), void 0 !== e.filmGauge && (o.filmGauge = e.filmGauge), void 0 !== e.filmOffset && (o.filmOffset = e.filmOffset), void 0 !== e.view && (o.view = Object.assign({}, e.view));
						break;
					case "OrthographicCamera":
						o = new ut(e.left, e.right, e.top, e.bottom, e.near, e.far);
						break;
					case "AmbientLight":
						o = new bn(e.color, e.intensity);
						break;
					case "Dt":
						o = new xn(e.color, e.intensity);
						break;
					case "PointLight":
						o = new _n(e.color, e.intensity, e.distance, e.decay);
						break;
					case "RectAreaLight":
						o = new wn(e.color, e.intensity, e.width, e.height);
						break;
					case "SpotLight":
						o = new vn(e.color, e.intensity, e.distance, e.angle, e.penumbra, e.decay);
						break;
					case "HemisphereLight":
						o = new dn(e.color, e.groundColor, e.intensity);
						break;
					case "SkinnedMesh":
					case "Mesh":
						var s = r(e.geometry),
							l = a(e.material);
						o = s.bones && s.bones.length > 0 ? new Te(s, l) : new Dt(s, l);
						break;
					case "Line":
						o = new Le(r(e.geometry), a(e.material), e.mode);
						break;
					case "LineLoop":
						o = new Pe(r(e.geometry), a(e.material));
						break;
					case "LineSegments":
						o = new Ce(r(e.geometry), a(e.material));
						break;
					case "PointCloud":
					case "Points":
						o = new Re(r(e.geometry), a(e.material));
						break;
					case "Sprite":
						o = new Se(a(e.material));
						break;
					case "Group":
						o = new Oe;
						break;
					default:
						o = new ct
				}
				if(o.uuid = e.uuid, void 0 !== e.name && (o.name = e.name), void 0 !== e.matrix ? (t.fromArray(e.matrix), t.decompose(o.position, o.quaternion, o.scale)) : (void 0 !== e.position && o.position.fromArray(e.position), void 0 !== e.rotation && o.rotation.fromArray(e.rotation), void 0 !== e.quaternion && o.quaternion.fromArray(e.quaternion), void 0 !== e.scale && o.scale.fromArray(e.scale)), void 0 !== e.castShadow && (o.castShadow = e.castShadow), void 0 !== e.receiveShadow && (o.receiveShadow = e.receiveShadow), e.shadow && (void 0 !== e.shadow.bias && (o.shadow.bias = e.shadow.bias), void 0 !== e.shadow.radius && (o.shadow.radius = e.shadow.radius), void 0 !== e.shadow.mapSize && o.shadow.mapSize.fromArray(e.shadow.mapSize), void 0 !== e.shadow.camera && (o.shadow.camera = this.parseObject(e.shadow.camera))), void 0 !== e.visible && (o.visible = e.visible), void 0 !== e.userData && (o.userData = e.userData), void 0 !== e.children)
					for(var c = e.children, h = 0; h < c.length; h++) o.add(this.parseObject(c[h], n, i));
				return o
			}
		}()
	});
	var so = {
			UVMapping: 300,
			CubeReflectionMapping: Pr,
			CubeRefractionMapping: Ir,
			EquirectangularReflectionMapping: Rr,
			EquirectangularRefractionMapping: Or,
			SphericalReflectionMapping: Nr,
			CubeUVReflectionMapping: Dr,
			CubeUVRefractionMapping: zr
		},
		lo = {
			RepeatWrapping: Ur,
			ClampToEdgeWrapping: Fr,
			MirroredRepeatWrapping: kr
		},
		co = {
			Nr: Br,
			NearestMipMapNr: Vr,
			NearestMipMapLinearFilter: jr,
			LinearFilter: Hr,
			LinearMipMapNr: Wr,
			LinearMipMapLinearFilter: Xr
		};
	Object.assign(qn.prototype, {
		getPoint: function() {
			return null
		},
		getPointAt: function(t, e) {
			var n = this.getUtoTmapping(t);
			return this.getPoint(n, e)
		},
		getPoints: function(t) {
			void 0 === t && (t = 5);
			for(var e = [], n = 0; n <= t; n++) e.push(this.getPoint(n / t));
			return e
		},
		getSpacedPoints: function(t) {
			void 0 === t && (t = 5);
			for(var e = [], n = 0; n <= t; n++) e.push(this.getPointAt(n / t));
			return e
		},
		getLength: function() {
			var t = this.getLengths();
			return t[t.length - 1]
		},
		getLengths: function(t) {
			if(void 0 === t && (t = this.arcLengthDivisions), this.cacheArcLengths && this.cacheArcLengths.length === t + 1 && !this.needsUpdate) return this.cacheArcLengths;
			this.needsUpdate = !1;
			var e, n, i = [],
				r = this.getPoint(0),
				a = 0;
			for(i.push(0), n = 1; n <= t; n++) a += (e = this.getPoint(n / t)).distanceTo(r), i.push(a), r = e;
			return this.cacheArcLengths = i, i
		},
		updateArcLengths: function() {
			this.needsUpdate = !0, this.getLengths()
		},
		getUtoTmapping: function(t, e) {
			var n, i = this.getLengths(),
				r = 0,
				a = i.length;
			n = e || t * i[a - 1];
			for(var o, s = 0, l = a - 1; s <= l;)
				if(r = Math.floor(s + (l - s) / 2), (o = i[r] - n) < 0) s = r + 1;
				else {
					if(!(o > 0)) {
						l = r;
						break
					}
					l = r - 1
				}
			if(r = l, i[r] === n) return r / (a - 1);
			var c = i[r];
			return(r + (n - c) / (i[r + 1] - c)) / (a - 1)
		},
		getTangent: function(t) {
			var e = t - 1e-4,
				n = t + 1e-4;
			e < 0 && (e = 0), n > 1 && (n = 1);
			var i = this.getPoint(e);
			return this.getPoint(n).clone().sub(i).normalize()
		},
		getTangentAt: function(t) {
			var e = this.getUtoTmapping(t);
			return this.getTangent(e)
		},
		computeFrenetFrames: function(t, e) {
			var n, r, o, s = new a,
				l = [],
				c = [],
				h = [],
				u = new a,
				f = new i;
			for(n = 0; n <= t; n++) r = n / t, l[n] = this.getTangentAt(r), l[n].normalize();
			c[0] = new a, h[0] = new a;
			var p = Number.MAX_VALUE,
				d = Math.abs(l[0].x),
				m = Math.abs(l[0].y),
				g = Math.abs(l[0].z);
			for(d <= p && (p = d, s.set(1, 0, 0)), m <= p && (p = m, s.set(0, 1, 0)), g <= p && s.set(0, 0, 1), u.crossVectors(l[0], s).normalize(), c[0].crossVectors(l[0], u), h[0].crossVectors(l[0], c[0]), n = 1; n <= t; n++) c[n] = c[n - 1].clone(), h[n] = h[n - 1].clone(), u.crossVectors(l[n - 1], l[n]), u.length() > Number.EPSILON && (u.normalize(), o = Math.acos(Oa.clamp(l[n - 1].dot(l[n]), -1, 1)), c[n].applyMatrix4(f.makeRotationAxis(u, o))), h[n].crossVectors(l[n], c[n]);
			if(!0 === e)
				for(o = Math.acos(Oa.clamp(c[0].dot(c[t]), -1, 1)), o /= t, l[0].dot(u.crossVectors(c[0], c[t])) > 0 && (o = -o), n = 1; n <= t; n++) c[n].applyMatrix4(f.makeRotationAxis(l[n], o * n)), h[n].crossVectors(l[n], c[n]);
			return {
				tangents: l,
				normals: c,
				binormals: h
			}
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.arcLengthDivisions = t.arcLengthDivisions, this
		}
	}), (Zn.prototype = Object.create(qn.prototype)).constructor = Zn, Zn.prototype.isLineCurve = !0, Zn.prototype.getPoint = function(t, e) {
		var i = e || new n;
		return 1 === t ? i.copy(this.v2) : (i.copy(this.v2).sub(this.v1), i.multiplyScalar(t).add(this.v1)), i
	}, Zn.prototype.getPointAt = function(t, e) {
		return this.getPoint(t, e)
	}, Zn.prototype.getTangent = function() {
		return this.v2.clone().sub(this.v1).normalize()
	}, Zn.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.v1.copy(t.v1), this.v2.copy(t.v2), this
	}, Jn.prototype = Object.assign(Object.create(qn.prototype), {
		constructor: Jn,
		add: function(t) {
			this.curves.push(t)
		},
		closePath: function() {
			var t = this.curves[0].getPoint(0),
				e = this.curves[this.curves.length - 1].getPoint(1);
			t.equals(e) || this.curves.push(new Zn(e, t))
		},
		getPoint: function(t) {
			for(var e = t * this.getLength(), n = this.getCurveLengths(), i = 0; i < n.length;) {
				if(n[i] >= e) {
					var r = n[i] - e,
						a = this.curves[i],
						o = a.getLength(),
						s = 0 === o ? 0 : 1 - r / o;
					return a.getPointAt(s)
				}
				i++
			}
			return null
		},
		getLength: function() {
			var t = this.getCurveLengths();
			return t[t.length - 1]
		},
		updateArcLengths: function() {
			this.needsUpdate = !0, this.cacheLengths = null, this.getCurveLengths()
		},
		getCurveLengths: function() {
			if(this.cacheLengths && this.cacheLengths.length === this.curves.length) return this.cacheLengths;
			for(var t = [], e = 0, n = 0, i = this.curves.length; n < i; n++) e += this.curves[n].getLength(), t.push(e);
			return this.cacheLengths = t, t
		},
		getSpacedPoints: function(t) {
			void 0 === t && (t = 40);
			for(var e = [], n = 0; n <= t; n++) e.push(this.getPoint(n / t));
			return this.autoClose && e.push(e[0]), e
		},
		getPoints: function(t) {
			t = t || 12;
			for(var e, n = [], i = 0, r = this.curves; i < r.length; i++)
				for(var a = r[i], o = a && a.isEllipseCurve ? 2 * t : a && a.isLineCurve ? 1 : a && a.isSplineCurve ? t * a.points.length : t, s = a.getPoints(o), l = 0; l < s.length; l++) {
					var c = s[l];
					e && e.equals(c) || (n.push(c), e = c)
				}
			return this.autoClose && n.length > 1 && !n[n.length - 1].equals(n[0]) && n.push(n[0]), n
		},
		copy: function(t) {
			qn.prototype.copy.call(this, t), this.curves = [];
			for(var e = 0, n = t.curves.length; e < n; e++) {
				var i = t.curves[e];
				this.curves.push(i.clone())
			}
			return this.autoClose = t.autoClose, this
		}
	}), Kn.prototype = Object.create(qn.prototype), Kn.prototype.constructor = Kn, Kn.prototype.isEllipseCurve = !0, Kn.prototype.getPoint = function(t, e) {
		for(var i = e || new n, r = 2 * Math.PI, a = this.aEndAngle - this.aStartAngle, o = Math.abs(a) < Number.EPSILON; a < 0;) a += r;
		for(; a > r;) a -= r;
		a < Number.EPSILON && (a = o ? 0 : r), !0 !== this.aClockwise || o || (a === r ? a = -r : a -= r);
		var s = this.aStartAngle + t * a,
			l = this.aX + this.xRadius * Math.cos(s),
			c = this.aY + this.yRadius * Math.sin(s);
		if(0 !== this.aRotation) {
			var h = Math.cos(this.aRotation),
				u = Math.sin(this.aRotation),
				f = l - this.aX,
				p = c - this.aY;
			l = f * h - p * u + this.aX, c = f * u + p * h + this.aY
		}
		return i.set(l, c)
	}, Kn.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.aX = t.aX, this.aY = t.aY, this.xRadius = t.xRadius, this.yRadius = t.yRadius, this.aStartAngle = t.aStartAngle, this.aEndAngle = t.aEndAngle, this.aClockwise = t.aClockwise, this.aRotation = t.aRotation, this
	}, (Qn.prototype = Object.create(qn.prototype)).constructor = Qn, Qn.prototype.isSplineCurve = !0, Qn.prototype.getPoint = function(t, e) {
		var i = e || new n,
			r = this.points,
			a = (r.length - 1) * t,
			o = Math.floor(a),
			s = a - o,
			l = r[0 === o ? o : o - 1],
			c = r[o],
			h = r[o > r.length - 2 ? r.length - 1 : o + 1],
			u = r[o > r.length - 3 ? r.length - 1 : o + 2];
		return i.set(Un(s, l.x, c.x, h.x, u.x), Un(s, l.y, c.y, h.y, u.y)), i
	}, Qn.prototype.copy = function(t) {
		qn.prototype.copy.call(this, t), this.points = [];
		for(var e = 0, n = t.points.length; e < n; e++) {
			var i = t.points[e];
			this.points.push(i.clone())
		}
		return this
	}, ($n.prototype = Object.create(qn.prototype)).constructor = $n, $n.prototype.isCubicBezierCurve = !0, $n.prototype.getPoint = function(t, e) {
		var i = e || new n,
			r = this.v0,
			a = this.v1,
			o = this.v2,
			s = this.v3;
		return i.set(Yn(t, r.x, a.x, o.x, s.x), Yn(t, r.y, a.y, o.y, s.y)), i
	}, $n.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.v0.copy(t.v0), this.v1.copy(t.v1), this.v2.copy(t.v2), this.v3.copy(t.v3), this
	}, (ti.prototype = Object.create(qn.prototype)).constructor = ti, ti.prototype.isQuadraticBezierCurve = !0, ti.prototype.getPoint = function(t, e) {
		var i = e || new n,
			r = this.v0,
			a = this.v1,
			o = this.v2;
		return i.set(Vn(t, r.x, a.x, o.x), Vn(t, r.y, a.y, o.y)), i
	}, ti.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.v0.copy(t.v0), this.v1.copy(t.v1), this.v2.copy(t.v2), this
	}, ei.prototype = Object.assign(Object.create(Jn.prototype), {
		constructor: ei,
		setFromPoints: function(t) {
			this.moveTo(t[0].x, t[0].y);
			for(var e = 1, n = t.length; e < n; e++) this.lineTo(t[e].x, t[e].y)
		},
		moveTo: function(t, e) {
			this.currentPoint.set(t, e)
		},
		lineTo: function(t, e) {
			var i = new Zn(this.currentPoint.clone(), new n(t, e));
			this.curves.push(i), this.currentPoint.set(t, e)
		},
		quadraticCurveTo: function(t, e, i, r) {
			var a = new ti(this.currentPoint.clone(), new n(t, e), new n(i, r));
			this.curves.push(a), this.currentPoint.set(i, r)
		},
		bezierCurveTo: function(t, e, i, r, a, o) {
			var s = new $n(this.currentPoint.clone(), new n(t, e), new n(i, r), new n(a, o));
			this.curves.push(s), this.currentPoint.set(a, o)
		},
		splineThru: function(t) {
			var e = new Qn([this.currentPoint.clone()].concat(t));
			this.curves.push(e), this.currentPoint.copy(t[t.length - 1])
		},
		arc: function(t, e, n, i, r, a) {
			var o = this.currentPoint.x,
				s = this.currentPoint.y;
			this.absarc(t + o, e + s, n, i, r, a)
		},
		absarc: function(t, e, n, i, r, a) {
			this.absellipse(t, e, n, n, i, r, a)
		},
		ellipse: function(t, e, n, i, r, a, o, s) {
			var l = this.currentPoint.x,
				c = this.currentPoint.y;
			this.absellipse(t + l, e + c, n, i, r, a, o, s)
		},
		absellipse: function(t, e, n, i, r, a, o, s) {
			var l = new Kn(t, e, n, i, r, a, o, s);
			if(this.curves.length > 0) {
				var c = l.getPoint(0);
				c.equals(this.currentPoint) || this.lineTo(c.x, c.y)
			}
			this.curves.push(l);
			var h = l.getPoint(1);
			this.currentPoint.copy(h)
		},
		copy: function(t) {
			return Jn.prototype.copy.call(this, t), this.currentPoint.copy(t.currentPoint), this
		}
	}), ni.prototype = Object.assign(Object.create(ei.prototype), {
		constructor: ni,
		getPointsHoles: function(t) {
			for(var e = [], n = 0, i = this.holes.length; n < i; n++) e[n] = this.holes[n].getPoints(t);
			return e
		},
		extractPoints: function(t) {
			return {
				shape: this.getPoints(t),
				holes: this.getPointsHoles(t)
			}
		},
		copy: function(t) {
			ei.prototype.copy.call(this, t), this.holes = [];
			for(var e = 0, n = t.holes.length; e < n; e++) {
				var i = t.holes[e];
				this.holes.push(i.clone())
			}
			return this
		}
	}), Object.assign(ii.prototype, {
		moveTo: function(t, e) {
			this.currentPath = new ei, this.subPaths.push(this.currentPath), this.currentPath.moveTo(t, e)
		},
		lineTo: function(t, e) {
			this.currentPath.lineTo(t, e)
		},
		quadraticCurveTo: function(t, e, n, i) {
			this.currentPath.quadraticCurveTo(t, e, n, i)
		},
		bezierCurveTo: function(t, e, n, i, r, a) {
			this.currentPath.bezierCurveTo(t, e, n, i, r, a)
		},
		splineThru: function(t) {
			this.currentPath.splineThru(t)
		},
		toShapes: function(t, e) {
			function n(t) {
				for(var e = [], n = 0, i = t.length; n < i; n++) {
					var r = t[n],
						a = new ni;
					a.curves = r.curves, e.push(a)
				}
				return e
			}
			var i = $a.isClockWise,
				r = this.subPaths;
			if(0 === r.length) return [];
			if(!0 === e) return n(r);
			var a, o, s, l = [];
			if(1 === r.length) return o = r[0], s = new ni, s.curves = o.curves, l.push(s), l;
			var c = !i(r[0].getPoints());
			c = t ? !c : c;
			var h, u = [],
				f = [],
				p = [],
				d = 0;
			f[d] = void 0, p[d] = [];
			for(var m = 0, g = r.length; m < g; m++) a = i(h = (o = r[m]).getPoints()), (a = t ? !a : a) ? (!c && f[d] && d++, f[d] = {
				s: new ni,
				p: h
			}, f[d].s.curves = o.curves, c && d++, p[d] = []) : p[d].push({
				h: o,
				p: h[0]
			});
			if(!f[0]) return n(r);
			if(f.length > 1) {
				for(var v = !1, _ = [], y = 0, x = f.length; y < x; y++) u[y] = [];
				for(var y = 0, x = f.length; y < x; y++)
					for(var b = p[y], w = 0; w < b.length; w++) {
						for(var M = b[w], S = !0, G = 0; G < f.length; G++)(function(t, e) {
							for(var n = e.length, i = !1, r = n - 1, a = 0; a < n; r = a++) {
								var o = e[r],
									s = e[a],
									l = s.x - o.x,
									c = s.y - o.y;
								if(Math.abs(c) > Number.EPSILON) {
									if(c < 0 && (o = e[a], l = -l, s = e[r], c = -c), t.y < o.y || t.y > s.y) continue;
									if(t.y === o.y) {
										if(t.x === o.x) return !0
									} else {
										var h = c * (t.x - o.x) - l * (t.y - o.y);
										if(0 === h) return !0;
										if(h < 0) continue;
										i = !i
									}
								} else {
									if(t.y !== o.y) continue;
									if(s.x <= t.x && t.x <= o.x || o.x <= t.x && t.x <= s.x) return !0
								}
							}
							return i
						})(M.p, f[G].p) && (y !== G && _.push({
							froms: y,
							tos: G,
							hole: w
						}), S ? (S = !1, u[G].push(M)) : v = !0);
						S && u[y].push(M)
					}
				_.length > 0 && (v || (p = u))
			}
			for(var E, m = 0, T = f.length; m < T; m++) {
				s = f[m].s, l.push(s);
				for(var A = 0, L = (E = p[m]).length; A < L; A++) s.holes.push(E[A].h)
			}
			return l
		}
	}), Object.assign(ri.prototype, {
		isFont: !0,
		generateShapes: function(t, e, n) {
			function i(t, e, n, i) {
				var a = r.glyphs[t] || r.glyphs["?"];
				if(a) {
					var o, s, l, c, h, u, f, p, d, m = new ii,
						g = [];
					if(a.o)
						for(var v = a._cachedOutline || (a._cachedOutline = a.o.split(" ")), _ = 0, y = v.length; _ < y;) switch(v[_++]) {
							case "m":
								o = v[_++] * e + n, s = v[_++] * e + i, m.moveTo(o, s);
								break;
							case "l":
								o = v[_++] * e + n, s = v[_++] * e + i, m.lineTo(o, s);
								break;
							case "q":
								l = v[_++] * e + n, c = v[_++] * e + i, h = v[_++] * e + n, u = v[_++] * e + i, m.quadraticCurveTo(h, u, l, c), (d = g[g.length - 1]) && (d.x, d.y);
								break;
							case "b":
								l = v[_++] * e + n, c = v[_++] * e + i, h = v[_++] * e + n, u = v[_++] * e + i, f = v[_++] * e + n, p = v[_++] * e + i, m.bezierCurveTo(h, u, f, p, l, c), (d = g[g.length - 1]) && (d.x, d.y)
						}
					return {
						offsetX: a.ha * e,
						path: m
					}
				}
			}
			void 0 === e && (e = 100), void 0 === n && (n = 4);
			for(var r = this.data, a = function(t) {
					for(var n = String(t).split(""), a = e / r.resolution, o = (r.boundingBox.yMax - r.boundingBox.yMin + r.underlineThickness) * a, s = 0, l = 0, c = [], h = 0; h < n.length; h++) {
						var u = n[h];
						if("\n" === u) s = 0, l -= o;
						else {
							var f = i(u, a, s, l);
							s += f.offsetX, c.push(f.path)
						}
					}
					return c
				}(t), o = [], s = 0, l = a.length; s < l; s++) Array.prototype.push.apply(o, a[s].toShapes());
			return o
		}
	}), Object.assign(ai.prototype, {
		load: function(t, e, n, i) {
			var r = this,
				a = new sn(this.manager);
			a.setPath(this.path), a.load(t, function(t) {
				var n;
				try {
					n = JSON.parse(t)
				} catch(e) {
					n = JSON.parse(t.substring(65, t.length - 2))
				}
				var i = r.parse(n);
				e && e(i)
			}, n, i)
		},
		parse: function(t) {
			return new ri(t)
		},
		setPath: function(t) {
			return this.path = t, this
		}
	});
	Object.assign(oi.prototype, {
		getValue: function(t, e) {
			this.bind();
			var n = this._targetGroup.nCachedObjects_,
				i = this._bindings[n];
			void 0 !== i && i.getValue(t, e)
		},
		setValue: function(t, e) {
			for(var n = this._bindings, i = this._targetGroup.nCachedObjects_, r = n.length; i !== r; ++i) n[i].setValue(t, e)
		},
		bind: function() {
			for(var t = this._bindings, e = this._targetGroup.nCachedObjects_, n = t.length; e !== n; ++e) t[e].bind()
		},
		unbind: function() {
			for(var t = this._bindings, e = this._targetGroup.nCachedObjects_, n = t.length; e !== n; ++e) t[e].unbind()
		}
	}), Object.assign(si, {
		Composite: oi,
		create: function(t, e, n) {
			return t && t.isAnimationObjectGroup ? new si.Composite(t, e, n) : new si(t, e, n)
		},
		sanitizeNodeName: function(t) {
			return t.replace(/\s/g, "_").replace(/[^\w-]/g, "")
		},
		parseTrackName: function() {
			var t = /((?:[\w-]+[\/:])*)/,
				e = /([\w-\.]+)?/,
				n = /(?:\.([\w-]+)(?:\[(.+)\])?)?/,
				i = /\.([\w-]+)(?:\[(.+)\])?/,
				r = new RegExp("^" + t.source + e.source + n.source + i.source + "$"),
				a = ["material", "materials", "bones"];
			return function(t) {
				var e = r.exec(t),
					n = {
						nodeName: e[2],
						objectName: e[3],
						objectIndex: e[4],
						propertyName: e[5],
						propertyIndex: e[6]
					},
					i = n.nodeName && n.nodeName.lastIndexOf(".");
				if(void 0 !== i && -1 !== i) {
					var o = n.nodeName.substring(i + 1); - 1 !== a.indexOf(o) && (n.nodeName = n.nodeName.substring(0, i), n.objectName = o)
				}
				return n
			}
		}(),
		findNode: function(t, e) {
			if(!e || "" === e || "root" === e || "." === e || -1 === e || e === t.name || e === t.uuid) return t;
			if(t.skeleton) {
				var n = function(t) {
					for(var n = 0; n < t.bones.length; n++) {
						var i = t.bones[n];
						if(i.name === e) return i
					}
					return null
				}(t.skeleton);
				if(n) return n
			}
			if(t.children) {
				var i = function(t) {
						for(var n = 0; n < t.length; n++) {
							var r = t[n];
							if(r.name === e || r.uuid === e) return r;
							var a = i(r.children);
							if(a) return a
						}
						return null
					},
					r = i(t.children);
				if(r) return r
			}
			return null
		}
	}), Object.assign(si.prototype, {
		_getValue_unavailable: function() {},
		_setValue_unavailable: function() {},
		BindingType: {
			Direct: 0,
			EntireArray: 1,
			ArrayElement: 2,
			HasFromToArray: 3
		},
		Versioning: {
			None: 0,
			NeedsUpdate: 1,
			MatrixWorldNeedsUpdate: 2
		},
		GetterByBindingType: [function(t, e) {
			t[e] = this.node[this.propertyName]
		}, function(t, e) {
			for(var n = this.resolvedProperty, i = 0, r = n.length; i !== r; ++i) t[e++] = n[i]
		}, function(t, e) {
			t[e] = this.resolvedProperty[this.propertyIndex]
		}, function(t, e) {
			this.resolvedProperty.toArray(t, e)
		}],
		SetterByBindingTypeAndVersioning: [
			[function(t, e) {
				this.targetObject[this.propertyName] = t[e]
			}, function(t, e) {
				this.targetObject[this.propertyName] = t[e], this.targetObject.needsUpdate = !0
			}, function(t, e) {
				this.targetObject[this.propertyName] = t[e], this.targetObject.mte = !0
			}],
			[function(t, e) {
				for(var n = this.resolvedProperty, i = 0, r = n.length; i !== r; ++i) n[i] = t[e++]
			}, function(t, e) {
				for(var n = this.resolvedProperty, i = 0, r = n.length; i !== r; ++i) n[i] = t[e++];
				this.targetObject.needsUpdate = !0
			}, function(t, e) {
				for(var n = this.resolvedProperty, i = 0, r = n.length; i !== r; ++i) n[i] = t[e++];
				this.targetObject.mte = !0
			}],
			[function(t, e) {
				this.resolvedProperty[this.propertyIndex] = t[e]
			}, function(t, e) {
				this.resolvedProperty[this.propertyIndex] = t[e], this.targetObject.needsUpdate = !0
			}, function(t, e) {
				this.resolvedProperty[this.propertyIndex] = t[e], this.targetObject.mte = !0
			}],
			[function(t, e) {
				this.resolvedProperty.fromArray(t, e)
			}, function(t, e) {
				this.resolvedProperty.fromArray(t, e), this.targetObject.needsUpdate = !0
			}, function(t, e) {
				this.resolvedProperty.fromArray(t, e), this.targetObject.mte = !0
			}]
		],
		getValue: function(t, e) {
			this.bind(), this.getValue(t, e)
		},
		setValue: function(t, e) {
			this.bind(), this.setValue(t, e)
		},
		bind: function() {
			var t = this.node,
				e = this.parsedPath,
				n = e.objectName,
				i = e.propertyName,
				r = e.propertyIndex;
			if(t || (t = si.findNode(this.rootNode, e.nodeName) || this.rootNode, this.node = t), this.getValue = this._getValue_unavailable, this.setValue = this._setValue_unavailable, t) {
				if(n) {
					var a = e.objectIndex;
					switch(n) {
						case "materials":
							if(!t.material) return;
							if(!t.material.materials) return;
							t = t.material.materials;
							break;
						case "bones":
							if(!t.skeleton) return;
							t = t.skeleton.bones;
							for(c = 0; c < t.length; c++)
								if(t[c].name === a) {
									a = c;
									break
								}
							break;
						default:
							if(void 0 === t[n]) return;
							t = t[n]
					}
					if(void 0 !== a) {
						if(void 0 === t[a]) return;
						t = t[a]
					}
				}
				var o = t[i];
				if(void 0 !== o) {
					var s = this.Versioning.None;
					void 0 !== t.needsUpdate ? (s = this.Versioning.NeedsUpdate, this.targetObject = t) : void 0 !== t.mte && (s = this.Versioning.MatrixWorldNeedsUpdate, this.targetObject = t);
					var l = this.BindingType.Direct;
					if(void 0 !== r) {
						if("morphTargetInfluences" === i) {
							if(!t.geometry) return;
							if(t.geometry.isBufferGeometry) {
								if(!t.geometry.morphAttributes) return;
								for(c = 0; c < this.node.geometry.morphAttributes.position.length; c++)
									if(t.geometry.morphAttributes.position[c].name === r) {
										r = c;
										break
									}
							} else {
								if(!t.geometry.morphTargets) return;
								for(var c = 0; c < this.node.geometry.morphTargets.length; c++)
									if(t.geometry.morphTargets[c].name === r) {
										r = c;
										break
									}
							}
						}
						l = this.BindingType.ArrayElement, this.resolvedProperty = o, this.propertyIndex = r
					} else void 0 !== o.fromArray && void 0 !== o.toArray ? (l = this.BindingType.HasFromToArray, this.resolvedProperty = o) : Array.isArray(o) ? (l = this.BindingType.EntireArray, this.resolvedProperty = o) : this.propertyName = i;
					this.getValue = this.GetterByBindingType[l], this.setValue = this.SetterByBindingTypeAndVersioning[l][s]
				} else e.nodeName
			}
		},
		unbind: function() {
			this.node = null, this.getValue = this._getValue_unbound, this.setValue = this._setValue_unbound
		}
	}), Object.assign(si.prototype, {
		_getValue_unbound: si.prototype.getValue,
		_setValue_unbound: si.prototype.setValue
	}), Object.assign(li.prototype, {
		isAnimationObjectGroup: !0,
		add: function() {
			for(var t = this._objects, e = t.length, n = this.nCachedObjects_, i = this._indicesByUUID, r = this._paths, a = this._parsedPaths, o = this._bindings, s = o.length, l = 0, c = arguments.length; l !== c; ++l) {
				var h = arguments[l],
					u = h.uuid,
					f = i[u];
				if(void 0 === f) {
					f = e++, i[u] = f, t.push(h);
					for(var p = 0, d = s; p !== d; ++p) o[p].push(new si(h, r[p], a[p]))
				} else if(f < n) {
					t[f];
					var m = --n,
						g = t[m];
					i[g.uuid] = f, t[f] = g, i[u] = m, t[m] = h;
					for(var p = 0, d = s; p !== d; ++p) {
						var v = o[p],
							_ = v[m],
							y = v[f];
						v[f] = _, void 0 === y && (y = new si(h, r[p], a[p])), v[m] = y
					}
				} else t[f]
			}
			this.nCachedObjects_ = n
		},
		remove: function() {
			for(var t = this._objects, e = this.nCachedObjects_, n = this._indicesByUUID, i = this._bindings, r = i.length, a = 0, o = arguments.length; a !== o; ++a) {
				var s = arguments[a],
					l = s.uuid,
					c = n[l];
				if(void 0 !== c && c >= e) {
					var h = e++,
						u = t[h];
					n[u.uuid] = c, t[c] = u, n[l] = h, t[h] = s;
					for(var f = 0, p = r; f !== p; ++f) {
						var d = i[f],
							m = d[h],
							g = d[c];
						d[c] = m, d[h] = g
					}
				}
			}
			this.nCachedObjects_ = e
		},
		uncache: function() {
			for(var t = this._objects, e = t.length, n = this.nCachedObjects_, i = this._indicesByUUID, r = this._bindings, a = r.length, o = 0, s = arguments.length; o !== s; ++o) {
				var l = arguments[o].uuid,
					c = i[l];
				if(void 0 !== c)
					if(delete i[l], c < n) {
						var h = --n,
							u = t[h],
							f = t[v = --e];
						i[u.uuid] = c, t[c] = u, i[f.uuid] = h, t[h] = f, t.pop();
						for(var p = 0, d = a; p !== d; ++p) {
							var m = (_ = r[p])[h],
								g = _[v];
							_[c] = m, _[h] = g, _.pop()
						}
					} else {
						var v = --e;
						i[(f = t[v]).uuid] = c, t[c] = f, t.pop();
						for(var p = 0, d = a; p !== d; ++p) {
							var _ = r[p];
							_[c] = _[v], _.pop()
						}
					}
			}
			this.nCachedObjects_ = n
		},
		subscribe_: function(t, e) {
			var n = this._bindingsIndicesByPath,
				i = n[t],
				r = this._bindings;
			if(void 0 !== i) return r[i];
			var a = this._paths,
				o = this._parsedPaths,
				s = this._objects,
				l = s.length,
				c = this.nCachedObjects_,
				h = new Array(l);
			i = r.length, n[t] = i, a.push(t), o.push(e), r.push(h);
			for(var u = c, f = s.length; u !== f; ++u) {
				var p = s[u];
				h[u] = new si(p, t, e)
			}
			return h
		},
		unsubscribe_: function(t) {
			var e = this._bindingsIndicesByPath,
				n = e[t];
			if(void 0 !== n) {
				var i = this._paths,
					r = this._parsedPaths,
					a = this._bindings,
					o = a.length - 1,
					s = a[o];
				e[t[o]] = n, a[n] = s, a.pop(), r[n] = r[o], r.pop(), i[n] = i[o], i.pop()
			}
		}
	}), ci.prototype.clone = function() {
		return new ci(void 0 === this.value.clone ? this.value : this.value.clone())
	}, hi.prototype = Object.assign(Object.create(Et.prototype), {
		constructor: hi,
		isInstancedBufferGeometry: !0,
		copy: function(t) {
			return Et.prototype.copy.call(this, t), this.maxInstancedCount = t.maxInstancedCount, this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		}
	}), Object.defineProperties(ui.prototype, {
		count: {
			get: function() {
				return this.data.count
			}
		},
		array: {
			get: function() {
				return this.data.array
			}
		}
	}), Object.assign(ui.prototype, {
		isInterleavedBufferAttribute: !0,
		setX: function(t, e) {
			return this.data.array[t * this.data.stride + this.offset] = e, this
		},
		setY: function(t, e) {
			return this.data.array[t * this.data.stride + this.offset + 1] = e, this
		},
		setZ: function(t, e) {
			return this.data.array[t * this.data.stride + this.offset + 2] = e, this
		},
		setW: function(t, e) {
			return this.data.array[t * this.data.stride + this.offset + 3] = e, this
		},
		getX: function(t) {
			return this.data.array[t * this.data.stride + this.offset]
		},
		getY: function(t) {
			return this.data.array[t * this.data.stride + this.offset + 1]
		},
		getZ: function(t) {
			return this.data.array[t * this.data.stride + this.offset + 2]
		},
		getW: function(t) {
			return this.data.array[t * this.data.stride + this.offset + 3]
		},
		setXY: function(t, e, n) {
			return t = t * this.data.stride + this.offset, this.data.array[t + 0] = e, this.data.array[t + 1] = n, this
		},
		setXYZ: function(t, e, n, i) {
			return t = t * this.data.stride + this.offset, this.data.array[t + 0] = e, this.data.array[t + 1] = n, this.data.array[t + 2] = i, this
		},
		setXYZW: function(t, e, n, i, r) {
			return t = t * this.data.stride + this.offset, this.data.array[t + 0] = e, this.data.array[t + 1] = n, this.data.array[t + 2] = i, this.data.array[t + 3] = r, this
		}
	}), Object.defineProperty(fi.prototype, "needsUpdate", {
		set: function(t) {
			!0 === t && this.version++
		}
	}), Object.assign(fi.prototype, {
		isInterleavedBuffer: !0,
		setArray: function(t) {
			this.count = void 0 !== t ? t.length / this.stride : 0, this.array = t
		},
		setDynamic: function(t) {
			return this.dynamic = t, this
		},
		copy: function(t) {
			return this.array = new t.array.constructor(t.array), this.count = t.count, this.stride = t.stride, this.dynamic = t.dynamic, this
		},
		copyAt: function(t, e, n) {
			t *= this.stride, n *= e.stride;
			for(var i = 0, r = this.stride; i < r; i++) this.array[t + i] = e.array[n + i];
			return this
		},
		set: function(t, e) {
			return void 0 === e && (e = 0), this.array.set(t, e), this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		onUpload: function(t) {
			return this.onUploadCallback = t, this
		}
	}), pi.prototype = Object.assign(Object.create(fi.prototype), {
		constructor: pi,
		isInstancedInterleavedBuffer: !0,
		copy: function(t) {
			return fi.prototype.copy.call(this, t), this.meshPerAttribute = t.meshPerAttribute, this
		}
	}), di.prototype = Object.assign(Object.create(dt.prototype), {
		constructor: di,
		isInstancedBufferAttribute: !0,
		copy: function(t) {
			return dt.prototype.copy.call(this, t), this.meshPerAttribute = t.meshPerAttribute, this
		}
	}), Object.assign(mi.prototype, {
		linePrecision: 1,
		set: function(t, e) {
			this.ray.set(t, e)
		},
		sa: function(t, e) {
			e && e.isPa ? (this.ray.origin.setFromMatrixPosition(e.matrixWorld), this.ray.direction.set(t.x, t.y, .5).unproject(e).sub(this.ray.origin).normalize()) : e && e.isOrthographicCamera && (this.ray.origin.set(t.x, t.y, (e.near + e.far) / (e.near - e.far)).unproject(e), this.ray.direction.set(0, 0, -1).transformDirection(e.matrixWorld))
		},
		intersectObject: function(t, e) {
			var n = [];
			return vi(t, this, n, e), n.sort(gi), n
		},
		is: function(t, e) {
			var n = [];
			if(!1 === Array.isArray(t)) return n;
			for(var i = 0, r = t.length; i < r; i++) vi(t[i], this, n, e);
			return n.sort(gi), n
		}
	}), Object.assign(_i.prototype, {
		start: function() {
			this.startTime = ("undefined" == typeof performance ? Date : performance).now(), this.oldTime = this.startTime, this.elapsedTime = 0, this.running = !0
		},
		stop: function() {
			this.getElapsedTime(), this.running = !1, this.autoStart = !1
		},
		getElapsedTime: function() {
			return this.getDelta(), this.elapsedTime
		},
		getDelta: function() {
			var t = 0;
			if(this.autoStart && !this.running) return this.start(), 0;
			if(this.running) {
				var e = ("undefined" == typeof performance ? Date : performance).now();
				t = (e - this.oldTime) / 1e3, this.oldTime = e, this.elapsedTime += t
			}
			return t
		}
	}), Object.assign(yi.prototype, {
		set: function(t, e, n) {
			return this.radius = t, this.phi = e, this.theta = n, this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.radius = t.radius, this.phi = t.phi, this.theta = t.theta, this
		},
		makeSafe: function() {
			return this.phi = Math.max(1e-6, Math.min(Math.PI - 1e-6, this.phi)), this
		},
		setFromVector3: function(t) {
			return this.radius = t.length(), 0 === this.radius ? (this.theta = 0, this.phi = 0) : (this.theta = Math.atan2(t.x, t.z), this.phi = Math.acos(Oa.clamp(t.y / this.radius, -1, 1))), this
		}
	}), Object.assign(xi.prototype, {
		set: function(t, e, n) {
			return this.radius = t, this.theta = e, this.y = n, this
		},
		clone: function() {
			return(new this.constructor).copy(this)
		},
		copy: function(t) {
			return this.radius = t.radius, this.theta = t.theta, this.y = t.y, this
		},
		setFromVector3: function(t) {
			return this.radius = Math.sqrt(t.x * t.x + t.z * t.z), this.theta = Math.atan2(t.x, t.z), this.y = t.y, this
		}
	}), bi.prototype = Object.create(Ce.prototype), bi.prototype.constructor = bi, bi.prototype.update = function() {
		var t = new et;
		return function(e) {
			if(void 0 !== this.object && t.st(this.object), !t.isEmpty()) {
				var n = t.min,
					i = t.max,
					r = this.geometry.attributes.position,
					a = r.array;
				a[0] = i.x, a[1] = i.y, a[2] = i.z, a[3] = n.x, a[4] = i.y, a[5] = i.z, a[6] = n.x, a[7] = n.y, a[8] = i.z, a[9] = i.x, a[10] = n.y, a[11] = i.z, a[12] = i.x, a[13] = i.y, a[14] = n.z, a[15] = n.x, a[16] = i.y, a[17] = n.z, a[18] = n.x, a[19] = n.y, a[20] = n.z, a[21] = i.x, a[22] = n.y, a[23] = n.z, r.needsUpdate = !0, this.geometry.computeBoundingSphere()
			}
		}
	}(), bi.prototype.st = function(t) {
		return this.object = t, this.update(), this
	}, (wi.prototype = Object.create(Ce.prototype)).constructor = wi, wi.prototype.uld = function(t) {
		var e = this.box;
		e.isEmpty() || (e.getCenter(this.position), e.getSize(this.scale), this.scale.multiplyScalar(.5), ct.prototype.uld.call(this, t))
	}, (Mi.prototype = Object.create(Le.prototype)).constructor = Mi, Mi.prototype.uld = function(t) {
		var e = -this.plane.constant;
		Math.abs(e) < 1e-8 && (e = 1e-8), this.scale.set(.5 * this.size, .5 * this.size, e), this.lookAt(this.plane.normal), ct.prototype.uld.call(this, t)
	};
	var ho, uo;
	(Si.prototype = Object.create(ct.prototype)).constructor = Si, Si.prototype.setDirection = function() {
		var t, e = new a;
		return function(n) {
			n.y > .99999 ? this.quaternion.set(0, 0, 0, 1) : n.y < -.99999 ? this.quaternion.set(1, 0, 0, 0) : (e.set(n.z, 0, -n.x).normalize(), t = Math.acos(n.y), this.quaternion.setFromAxisAngle(e, t))
		}
	}(), Si.prototype.setLength = function(t, e, n) {
		void 0 === e && (e = .2 * t), void 0 === n && (n = .2 * e), this.line.scale.set(1, Math.max(0, t - e), 1), this.line.updateMatrix(), this.cone.scale.set(n, e, n), this.cone.position.y = t, this.cone.updateMatrix()
	}, Si.prototype.setColor = function(t) {
		this.line.material.color.copy(t), this.cone.material.color.copy(t)
	}, Gi.prototype = Object.create(Ce.prototype), Gi.prototype.constructor = Gi;
	var fo = new a,
		po = new Ei,
		mo = new Ei,
		go = new Ei;
	Ti.prototype = Object.create(qn.prototype), Ti.prototype.constructor = Ti, Ti.prototype.isCatmullRomCurve3 = !0, Ti.prototype.getPoint = function(t, e) {
		var n = e || new a,
			i = this.points,
			r = i.length,
			o = (r - (this.closed ? 0 : 1)) * t,
			s = Math.floor(o),
			l = o - s;
		this.closed ? s += s > 0 ? 0 : (Math.floor(Math.abs(s) / i.length) + 1) * i.length : 0 === l && s === r - 1 && (s = r - 2, l = 1);
		var c, h, u, f;
		if(this.closed || s > 0 ? c = i[(s - 1) % r] : (fo.subVectors(i[0], i[1]).add(i[0]), c = fo), h = i[s % r], u = i[(s + 1) % r], this.closed || s + 2 < r ? f = i[(s + 2) % r] : (fo.subVectors(i[r - 1], i[r - 2]).add(i[r - 1]), f = fo), "centripetal" === this.curveType || "chordal" === this.curveType) {
			var p = "chordal" === this.curveType ? .5 : .25,
				d = Math.pow(c.distanceToSquared(h), p),
				m = Math.pow(h.distanceToSquared(u), p),
				g = Math.pow(u.distanceToSquared(f), p);
			m < 1e-4 && (m = 1), d < 1e-4 && (d = m), g < 1e-4 && (g = m), po.initNonuniformCatmullRom(c.x, h.x, u.x, f.x, d, m, g), mo.initNonuniformCatmullRom(c.y, h.y, u.y, f.y, d, m, g), go.initNonuniformCatmullRom(c.z, h.z, u.z, f.z, d, m, g)
		} else "catmullrom" === this.curveType && (po.initCatmullRom(c.x, h.x, u.x, f.x, this.tension), mo.initCatmullRom(c.y, h.y, u.y, f.y, this.tension), go.initCatmullRom(c.z, h.z, u.z, f.z, this.tension));
		return n.set(po.calc(l), mo.calc(l), go.calc(l)), n
	}, Ti.prototype.copy = function(t) {
		qn.prototype.copy.call(this, t), this.points = [];
		for(var e = 0, n = t.points.length; e < n; e++) {
			var i = t.points[e];
			this.points.push(i.clone())
		}
		return this.closed = t.closed, this.curveType = t.curveType, this.tension = t.tension, this
	}, (Ai.prototype = Object.create(qn.prototype)).constructor = Ai, Ai.prototype.isCubicBezierCurve3 = !0, Ai.prototype.getPoint = function(t, e) {
		var n = e || new a,
			i = this.v0,
			r = this.v1,
			o = this.v2,
			s = this.v3;
		return n.set(Yn(t, i.x, r.x, o.x, s.x), Yn(t, i.y, r.y, o.y, s.y), Yn(t, i.z, r.z, o.z, s.z)), n
	}, Ai.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.v0.copy(t.v0), this.v1.copy(t.v1), this.v2.copy(t.v2), this.v3.copy(t.v3), this
	}, (Li.prototype = Object.create(qn.prototype)).constructor = Li, Li.prototype.isQuadraticBezierCurve3 = !0, Li.prototype.getPoint = function(t, e) {
		var n = e || new a,
			i = this.v0,
			r = this.v1,
			o = this.v2;
		return n.set(Vn(t, i.x, r.x, o.x), Vn(t, i.y, r.y, o.y), Vn(t, i.z, r.z, o.z)), n
	}, Li.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.v0.copy(t.v0), this.v1.copy(t.v1), this.v2.copy(t.v2), this
	}, (Ci.prototype = Object.create(qn.prototype)).constructor = Ci, Ci.prototype.isLineCurve3 = !0, Ci.prototype.getPoint = function(t, e) {
		var n = e || new a;
		return 1 === t ? n.copy(this.v2) : (n.copy(this.v2).sub(this.v1), n.multiplyScalar(t).add(this.v1)), n
	}, Ci.prototype.getPointAt = function(t, e) {
		return this.getPoint(t, e)
	}, Ci.prototype.copy = function(t) {
		return qn.prototype.copy.call(this, t), this.v1.copy(t.v1), this.v2.copy(t.v2), this
	}, (Pi.prototype = Object.create(Kn.prototype)).constructor = Pi, Pi.prototype.isArcCurve = !0;
	var vo = {
		createMultiMaterialObject: function(t, e) {
			for(var n = new Oe, i = 0, r = e.length; i < r; i++) n.add(new Dt(t, e[i]));
			return n
		},
		detach: function(t, e, n) {
			t.applyMatrix(e.matrixWorld), e.remove(t), n.add(t)
		},
		attach: function(t, e, n) {
			t.applyMatrix((new i).getInverse(n.matrixWorld)), e.remove(t), n.add(t)
		}
	};
	qn.create = function(t, e) {
		return t.prototype = Object.create(qn.prototype), t.prototype.constructor = t, t.prototype.getPoint = e, t
	}, Object.assign(Jn.prototype, {
		createPointsGeometry: function(t) {
			var e = this.getPoints(t);
			return this.createGeometry(e)
		},
		createSpacedPointsGeometry: function(t) {
			var e = this.getSpacedPoints(t);
			return this.createGeometry(e)
		},
		createGeometry: function(t) {
			for(var e = new pt, n = 0, i = t.length; n < i; n++) {
				var r = t[n];
				e.vertices.push(new a(r.x, r.y, r.z || 0))
			}
			return e
		}
	}), Object.assign(ei.prototype, {
		fromPoints: function(t) {
			this.setFromPoints(t)
		}
	}), Ii.prototype = Object.create(Ti.prototype), Ri.prototype = Object.create(Ti.prototype), Oi.prototype = Object.create(Ti.prototype), Object.assign(Oi.prototype, {
		initFromArray: function() {},
		getControlPointsArray: function() {},
		reparametrizeByArcLength: function() {}
	}), Object.assign(q.prototype, {
		center: function(t) {
			return this.getCenter(t)
		},
		empty: function() {
			return this.isEmpty()
		},
		isIntersectionBox: function(t) {
			return this.intersectsBox(t)
		},
		size: function(t) {
			return this.getSize(t)
		}
	}), Object.assign(et.prototype, {
		center: function(t) {
			return this.getCenter(t)
		},
		empty: function() {
			return this.isEmpty()
		},
		isIntersectionBox: function(t) {
			return this.intersectsBox(t)
		},
		isIntersectionSphere: function(t) {
			return this.intersectsSphere(t)
		},
		size: function(t) {
			return this.getSize(t)
		}
	}), Ot.prototype.center = function(t) {
		return this.getCenter(t)
	}, Object.assign(Oa, {
		random16: function() {
			return Math.random()
		},
		nearestPowerOfTwo: function(t) {
			return Oa.floorPowerOfTwo(t)
		},
		nextPowerOfTwo: function(t) {
			return Oa.ceilPowerOfTwo(t)
		}
	}), Object.assign(o.prototype, {
		flattenToArrayOffset: function(t, e) {
			return this.toArray(t, e)
		},
		multiplyVector3: function(t) {
			return t.applyMatrix3(this)
		},
		multiplyVector3Array: function() {},
		applyToBuffer: function(t) {
			return this.applyToBufferAttribute(t)
		},
		applyToVector3Array: function() {}
	}), Object.assign(i.prototype, {
		extractPosition: function(t) {
			return this.copyPosition(t)
		},
		flattenToArrayOffset: function(t, e) {
			return this.toArray(t, e)
		},
		getPosition: function() {
			var t;
			return function() {
				return void 0 === t && (t = new a), t.setFromMatrixColumn(this, 3)
			}
		}(),
		setRotationFromQuaternion: function(t) {
			return this.makeRotationFromQuaternion(t)
		},
		multiplyToArray: function() {},
		multiplyVector3: function(t) {
			return t.applyMatrix4(this)
		},
		multiplyVector4: function(t) {
			return t.applyMatrix4(this)
		},
		multiplyVector3Array: function() {},
		rotateAxis: function(t) {
			t.transformDirection(this)
		},
		crossVector: function(t) {
			return t.applyMatrix4(this)
		},
		translate: function() {},
		rotateX: function() {},
		rotateY: function() {},
		rotateZ: function() {},
		rotateByAxis: function() {},
		applyToBuffer: function(t) {
			return this.applyToBufferAttribute(t)
		},
		applyToVector3Array: function() {},
		makeFrustum: function(t, e, n, i, r, a) {
			return this.makePerspective(t, e, i, n, r, a)
		}
	}), it.prototype.isIntersectionLine = function(t) {
		return this.intersectsLine(t)
	}, r.prototype.multiplyVector3 = function(t) {
		return t.applyQuaternion(this)
	}, Object.assign(Rt.prototype, {
		isIntersectionBox: function(t) {
			return this.intersectsBox(t)
		},
		isIntersectionPlane: function(t) {
			return this.intersectsPlane(t)
		},
		isIntersectionSphere: function(t) {
			return this.intersectsSphere(t)
		}
	}), Object.assign(ni.prototype, {
		extractAllPoints: function(t) {
			return this.extractPoints(t)
		},
		makeGeometry: function(t) {
			return new Be(this, t)
		}
	}), Object.assign(n.prototype, {
		fromAttribute: function(t, e, n) {
			return this.fromBufferAttribute(t, e, n)
		},
		distanceToManhattan: function(t) {
			return this.manhattanDistanceTo(t)
		},
		lengthManhattan: function() {
			return this.manhattanLength()
		}
	}), Object.assign(a.prototype, {
		setEulerFromRotationMatrix: function() {},
		setEulerFromQuaternion: function() {},
		getPositionFromMatrix: function(t) {
			return this.setFromMatrixPosition(t)
		},
		getScaleFromMatrix: function(t) {
			return this.setFromMatrixScale(t)
		},
		getColumnFromMatrix: function(t, e) {
			return this.setFromMatrixColumn(e, t)
		},
		applyProjection: function(t) {
			return this.applyMatrix4(t)
		},
		fromAttribute: function(t, e, n) {
			return this.fromBufferAttribute(t, e, n)
		},
		distanceToManhattan: function(t) {
			return this.manhattanDistanceTo(t)
		},
		lengthManhattan: function() {
			return this.manhattanLength()
		}
	}), Object.assign(l.prototype, {
		fromAttribute: function(t, e, n) {
			return this.fromBufferAttribute(t, e, n)
		},
		lengthManhattan: function() {
			return this.manhattanLength()
		}
	}), pt.prototype.computeTangents = function() {}, Object.assign(ct.prototype, {
		getChildByName: function(t) {
			return this.ge(t)
		},
		renderDepth: function() {},
		translate: function(t, e) {
			return this.translateOnAxis(e, t)
		}
	}), Object.defineProperties(ct.prototype, {
		eulerOrder: {
			get: function() {
				return this.rotation.order
			},
			set: function(t) {
				this.rotation.order = t
			}
		},
		useQuaternion: {
			get: function() {},
			set: function() {}
		}
	}), Object.defineProperty(Ge.prototype, "useVertexTexture", {
		get: function() {},
		set: function() {}
	}), Object.defineProperty(qn.prototype, "__arcLengthDivisions", {
		get: function() {
			return this.arcLengthDivisions
		},
		set: function(t) {
			this.arcLengthDivisions = t
		}
	}), de.prototype.setLens = function(t, e) {
		void 0 !== e && (this.filmGauge = e), this.setFocalLength(t)
	}, Object.defineProperties(pn.prototype, {
		onlyShadow: {
			set: function() {}
		},
		shadowCameraFov: {
			set: function(t) {
				this.shadow.camera.fov = t
			}
		},
		shadowCameraLeft: {
			set: function(t) {
				this.shadow.camera.left = t
			}
		},
		shadowCameraRight: {
			set: function(t) {
				this.shadow.camera.right = t
			}
		},
		shadowCameraTop: {
			set: function(t) {
				this.shadow.camera.top = t
			}
		},
		shadowCameraBottom: {
			set: function(t) {
				this.shadow.camera.bottom = t
			}
		},
		shadowCameraNear: {
			set: function(t) {
				this.shadow.camera.near = t
			}
		},
		shadowCameraFar: {
			set: function(t) {
				this.shadow.camera.far = t
			}
		},
		shadowCameraVisible: {
			set: function() {}
		},
		shadowBias: {
			set: function(t) {
				this.shadow.bias = t
			}
		},
		shadowDarkness: {
			set: function() {}
		},
		shadowMapWidth: {
			set: function(t) {
				this.shadow.mapSize.width = t
			}
		},
		shadowMapHeight: {
			set: function(t) {
				this.shadow.mapSize.height = t
			}
		}
	}), Object.defineProperties(dt.prototype, {
		length: {
			get: function() {
				return this.array.length
			}
		}
	}), Object.assign(Et.prototype, {
		addIndex: function(t) {
			this.setIndex(t)
		},
		addDrawCall: function(t, e, n) {
			this.addGroup(t, e)
		},
		clearDrawCalls: function() {
			this.clearGroups()
		},
		computeTangents: function() {},
		computeOffsets: function() {}
	}), Object.defineProperties(Et.prototype, {
		drawcalls: {
			get: function() {
				return this.groups
			}
		},
		offsets: {
			get: function() {
				return this.groups
			}
		}
	}), Object.defineProperties(ci.prototype, {
		dynamic: {
			set: function() {}
		},
		onUpdate: {
			value: function() {
				return this
			}
		}
	}), Object.defineProperties(Q.prototype, {
		wrapAround: {
			get: function() {},
			set: function() {}
		},
		wrapRGB: {
			get: function() {
				return new Y
			}
		},
		shading: {
			get: function() {},
			set: function(t) {
				this.flatShading = 1 === t
			}
		}
	}), Object.defineProperties(tn.prototype, {
		metal: {
			get: function() {
				return !1
			},
			set: function() {}
		}
	}), Object.defineProperties(It.prototype, {
		derivatives: {
			get: function() {
				return this.extensions.derivatives
			},
			set: function(t) {
				this.extensions.derivatives = t
			}
		}
	}), Object.assign(ye.prototype, {
		getCurrentRenderTarget: function() {
			return this.getRenderTarget()
		},
		getMaxAnisotropy: function() {
			return this.capabilities.getMaxAnisotropy()
		},
		getPrecision: function() {
			return this.capabilities.precision
		},
		resetGLState: function() {
			return this.state.reset()
		},
		supportsFloatTextures: function() {
			return this.extensions.get("OES_texture_float")
		},
		supportsHalfFloatTextures: function() {
			return this.extensions.get("OES_texture_half_float")
		},
		supportsStandardDerivatives: function() {
			return this.extensions.get("OES_standard_derivatives")
		},
		supportsCompressedTextureS3TC: function() {
			return this.extensions.get("WEBGL_compressed_texture_s3tc")
		},
		supportsCompressedTexturePVRTC: function() {
			return this.extensions.get("WEBGL_compressed_texture_pvrtc")
		},
		supportsBlendMinMax: function() {
			return this.extensions.get("EXT_blend_minmax")
		},
		supportsVertexTextures: function() {
			return this.capabilities.vertexTextures
		},
		supportsInstancedArrays: function() {
			return this.extensions.get("ANGLE_instanced_arrays")
		},
		enableScissorTest: function(t) {
			this.setScissorTest(t)
		},
		initMaterial: function() {},
		addPrePlugin: function() {},
		addPostPlugin: function() {},
		updateShadowMap: function() {}
	}), Object.defineProperties(ye.prototype, {
		shadowMapEnabled: {
			get: function() {
				return this.shadowMap.enabled
			},
			set: function(t) {
				this.shadowMap.enabled = t
			}
		},
		shadowMapType: {
			get: function() {
				return this.shadowMap.type
			},
			set: function(t) {
				this.shadowMap.type = t
			}
		},
		shadowMapCullFace: {
			get: function() {
				return this.shadowMap.cullFace
			},
			set: function(t) {
				this.shadowMap.cullFace = t
			}
		}
	}), Object.defineProperties(at.prototype, {
		cullFace: {
			get: function() {
				return this.renderReverseSided ? Ui : zi
			},
			set: function(t) {
				var e = t !== zi;
				this.renderReverseSided = e
			}
		}
	}), Object.defineProperties(c.prototype, {
		wrapS: {
			get: function() {
				return this.texture.wrapS
			},
			set: function(t) {
				this.texture.wrapS = t
			}
		},
		wrapT: {
			get: function() {
				return this.texture.wrapT
			},
			set: function(t) {
				this.texture.wrapT = t
			}
		},
		magFilter: {
			get: function() {
				return this.texture.magFilter
			},
			set: function(t) {
				this.texture.magFilter = t
			}
		},
		minFilter: {
			get: function() {
				return this.texture.minFilter
			},
			set: function(t) {
				this.texture.minFilter = t
			}
		},
		anisotropy: {
			get: function() {
				return this.texture.anisotropy
			},
			set: function(t) {
				this.texture.anisotropy = t
			}
		},
		offset: {
			get: function() {
				return this.texture.offset
			},
			set: function(t) {
				this.texture.offset = t
			}
		},
		repeat: {
			get: function() {
				return this.texture.repeat
			},
			set: function(t) {
				this.texture.repeat = t
			}
		},
		format: {
			get: function() {
				return this.texture.format
			},
			set: function(t) {
				this.texture.format = t
			}
		},
		type: {
			get: function() {
				return this.texture.type
			},
			set: function(t) {
				this.texture.type = t
			}
		},
		generateMipmaps: {
			get: function() {
				return this.texture.generateMipmaps
			},
			set: function(t) {
				this.texture.generateMipmaps = t
			}
		}
	});
	var _o = {
			merge: function(t, e, n) {
				var i;
				e.isMesh && (e.matrixAutoUpdate && e.updateMatrix(), i = e.matrix, e = e.geometry), t.merge(e, i, n)
			},
			center: function(t) {
				return t.center()
			}
		},
		yo = {
			crossOrigin: void 0,
			loadTexture: function(t, e, n, i) {
				var r = new fn;
				r.setCrossOrigin(this.crossOrigin);
				var a = r.load(t, n, void 0, i);
				return e && (a.mapping = e), a
			},
			loadTextureCube: function(t, e, n, i) {
				var r = new un;
				r.setCrossOrigin(this.crossOrigin);
				var a = r.load(t, n, void 0, i);
				return e && (a.mapping = e), a
			},
			loadCompressedTexture: function() {},
			loadCompressedTextureCube: function() {}
		};
	t.WtCube = h, t.Wt = c, t.Wr = ye, t.ShaderLib = Ya, t.UniformsLib = Ha, t.UniformsUtils = Wa, t.ShaderChunk = Xa, t.Fog = xe, t.Scene = be, t.LensFlare = we, t.Sprite = Se, t.SkinnedMesh = Te, t.Skeleton = Ge, t.Bone = Ee, t.Mesh = Dt, t.LineSegments = Ce, t.LineLoop = Pe, t.Line = Le, t.Points = Re, t.Group = Oe, t.VideoTexture = Ne, t.DataTexture = u, t.CompressedTexture = De, t.CubeTexture = f, t.CanvasTexture = J, t.DepthTexture = ze, t.Texture = s, t.CompressedTextureLoader = ln, t.DataTextureLoader = cn, t.CubeTextureLoader = un, t.TextureLoader = fn, t.ObjectLoader = zn, t.MaterialLoader = Rn, t.BufferGeometryLoader = On, t.DefaultLr = io, t.Lr = on, t.JSONLoader = Dn, t.Ir = hn, t.FontLoader = ai, t.FileLoader = sn, t.Loader = Nn, t.Cache = no, t.SpotLightShadow = gn, t.SpotLight = vn, t.PointLight = _n, t.RectAreaLight = wn, t.HemisphereLight = dn, t.DtShadow = yn, t.Dt = xn, t.AmbientLight = bn, t.LightShadow = mn, t.Light = pn, t.Pa = de, t.OrthographicCamera = ut, t.ArrayCamera = me, t.Camera = ht, t.VectorKeyframeTrack = Pn, t.QuaternionKeyframeTrack = Gn, t.NumberKeyframeTrack = En, t.PropertyBinding = si, t.KeyframeTrack = Cn, t.AnimationUtils = ao, t.AnimationObjectGroup = li, t.AnimationClip = In, t.Uniform = ci, t.InstancedBufferGeometry = hi, t.BufferGeometry = Et, t.Geometry = pt, t.InterleavedBufferAttribute = ui, t.InstancedInterleavedBuffer = pi, t.InterleavedBuffer = fi, t.InstancedBufferAttribute = di, t.Face3 = ft, t.Object3D = ct, t.Rr = mi, t.Layers = lt, t.EventDispatcher = e, t.Clock = _i, t.QuaternionLinearInterpolant = Sn, t.LinearInterpolant = An, t.DiscreteInterpolant = Ln, t.CubicInterpolant = Tn, t.Interpolant = Mn, t.Triangle = Nt, t.Math = Oa, t.Spherical = yi, t.Cylindrical = xi, t.Plane = it, t.Frustum = rt, t.Sphere = nt, t.Ray = Rt, t.Matrix4 = i, t.Matrix3 = o, t.Box3 = et, t.Box2 = q, t.Line3 = Ot, t.Euler = st, t.Vector4 = l, t.Vector3 = a, t.Vector2 = n, t.Quaternion = r, t.Color = Y, t.Br = bi, t.Box3Helper = wi, t.pr = Mi, t.ArrowHelper = Si, t.AxesHelper = Gi, t.CatmullRomCurve3 = Ti, t.CubicBezierCurve3 = Ai, t.QuadraticBezierCurve3 = Li, t.LineCurve3 = Ci, t.ArcCurve = Pi, t.EllipseCurve = Kn, t.SplineCurve = Qn, t.CubicBezierCurve = $n, t.QuadraticBezierCurve = ti, t.LineCurve = Zn, t.Shape = ni, t.Path = ei, t.ShapePath = ii, t.Font = ri, t.CurvePath = Jn, t.Curve = qn, t.ShapeUtils = $a, t.SceneUtils = vo, t.WebGLUtils = _e, t.WireframeGeometry = Ue, t.SphereGeometry = Fe, t.SphereBufferGeometry = ke, t.PlaneGeometry = Lt, t.PlaneBufferGeometry = Ct, t.ShapeGeometry = Be, t.ShapeBufferGeometry = Ve, t.EdgesGeometry = je, t.ConeGeometry = Xe, t.ConeBufferGeometry = Ye, t.CylinderGeometry = He, t.CylinderBufferGeometry = We, t.CircleGeometry = qe, t.CircleBufferGeometry = Ze, t.BoxGeometry = Tt, t.By = At, t.ShadowMaterial = Je, t.SpriteMaterial = Me, t.RawShaderMaterial = Ke, t.ShaderMaterial = It, t.PointsMaterial = Ie, t.MeshPhysicalMaterial = $e, t.MeshStandardMaterial = Qe, t.MeshPhongMaterial = tn, t.MeshToonMaterial = en, t.MeshNormalMaterial = nn, t.MeshLambertMaterial = rn, t.MeshDepthMaterial = $, t.MeshDistanceMaterial = tt, t.Mal = Pt, t.LineDashedMaterial = an, t.LineBasicMaterial = Ae, t.Material = Q, t.Float64BufferAttribute = Mt, t.Float32BufferAttribute = wt, t.Uint32BufferAttribute = bt, t.Int32BufferAttribute = xt, t.Uint16BufferAttribute = yt, t.Int16BufferAttribute = _t, t.Uint8ClampedBufferAttribute = vt, t.Uint8BufferAttribute = gt, t.Int8BufferAttribute = mt, t.BufferAttribute = dt, t.REVISION = "bim4", t.MOUSE = Ni, t.CullFaceNone = Di, t.CullFaceBack = zi, t.CullFaceFront = Ui, t.CullFaceFrontBack = 3, t.FrontFaceDirectionCW = Fi, t.FrontFaceDirectionCCW = 1, t.BasicShadowMap = 0, t.PCFShadowMap = ki, t.PCFSoftShadowMap = Bi, t.FrontSide = Vi, t.BackSide = ji, t.DoubleSide = Hi, t.FlatShading = 1, t.SmoothShading = 2, t.NoColors = Wi, t.FaceColors = 1, t.VertexColors = Xi, t.NoBlending = Yi, t.NormalBlending = qi, t.AdditiveBlending = Zi, t.SubtractiveBlending = Ji, t.MultiplyBlending = Ki, t.CustomBlending = Qi, t.AddEquation = $i, t.SubtractEquation = tr, t.ReverseSubtractEquation = er, t.MinEquation = nr, t.MaxEquation = ir, t.ZeroFactor = rr, t.OneFactor = ar, t.SrcColorFactor = or, t.OneMinusSrcColorFactor = sr, t.SrcAlphaFactor = lr, t.OneMinusSrcAlphaFactor = cr, t.DstAlphaFactor = hr, t.OneMinusDstAlphaFactor = ur, t.DstColorFactor = fr, t.OneMinusDstColorFactor = pr, t.SrcAlphaSaturateFactor = dr, t.NeverDepth = mr, t.AlwaysDepth = gr, t.LessDepth = vr, t.LessEqualDepth = _r, t.EqualDepth = yr, t.GreaterEqualDepth = xr, t.GreaterDepth = br, t.NotEqualDepth = wr, t.MultiplyOperation = Mr, t.MixOperation = Sr, t.AddOperation = Gr, t.NoToneMapping = Er, t.LinearToneMapping = Tr, t.ReinhardToneMapping = Ar, t.Uncharted2ToneMapping = Lr, t.CineonToneMapping = Cr, t.UVMapping = 300, t.CubeReflectionMapping = Pr, t.CubeRefractionMapping = Ir, t.EquirectangularReflectionMapping = Rr, t.EquirectangularRefractionMapping = Or, t.SphericalReflectionMapping = Nr, t.CubeUVReflectionMapping = Dr, t.CubeUVRefractionMapping = zr, t.RepeatWrapping = Ur, t.ClampToEdgeWrapping = Fr, t.MirroredRepeatWrapping = kr, t.Nr = Br, t.NearestMipMapNr = Vr, t.NearestMipMapLinearFilter = jr, t.LinearFilter = Hr, t.LinearMipMapNr = Wr, t.LinearMipMapLinearFilter = Xr, t.UnsignedByteType = Yr, t.ByteType = qr, t.ShortType = Zr, t.UnsignedShortType = Jr, t.IntType = Kr, t.UnsignedIntType = Qr, t.FloatType = $r, t.HalfFloatType = ta, t.UnsignedShort4444Type = ea, t.UnsignedShort5551Type = na, t.UnsignedShort565Type = ia, t.UnsignedInt248Type = ra, t.AlphaFormat = aa, t.RGBFormat = oa, t.RGBAFormat = sa, t.LuminanceFormat = la, t.LuminanceAlphaFormat = ca, t.RGBEFormat = ha, t.DepthFormat = ua, t.DepthStencilFormat = fa, t.RGB_S3TC_DXT1_Format = pa, t.RGBA_S3TC_DXT1_Format = da, t.RGBA_S3TC_DXT3_Format = ma, t.RGBA_S3TC_DXT5_Format = ga, t.RGB_PVRTC_4BPPV1_Format = va, t.RGB_PVRTC_2BPPV1_Format = _a, t.RGBA_PVRTC_4BPPV1_Format = ya, t.RGBA_PVRTC_2BPPV1_Format = xa, t.RGB_ETC1_Format = ba, t.LoopOnce = 2200, t.LoopRepeat = 2201, t.LoopPingPong = 2202, t.InterpolateDiscrete = 2300, t.InterpolateLinear = 2301, t.InterpolateSmooth = 2302, t.ZeroCurvatureEnding = 2400, t.ZeroSlopeEnding = 2401, t.WrapAroundEnding = 2402, t.TrianglesDrawMode = wa, t.TriangleStripDrawMode = Ma, t.TriangleFanDrawMode = Sa, t.LinearEncoding = Ga, t.sRGBEncoding = Ea, t.GammaEncoding = Ta, t.RGBEEncoding = Aa, t.LogLuvEncoding = 3003, t.RGBM7Encoding = La, t.RGBM16Encoding = Ca, t.RGBDEncoding = Pa, t.BasicDepthPacking = Ia, t.RGBADepthPacking = Ra, t.CubeGeometry = Tt, t.Face4 = function(t, e, n, i, r, a, o) {
		return new ft(t, e, n, r, a, o)
	}, t.LineStrip = 0, t.LinePieces = 1, t.MeshFaceMaterial = function(t) {
		return t
	}, t.MultiMaterial = function(t) {
		return void 0 === t && (t = []), t.isMultiMaterial = !0, t.materials = t, t.clone = function() {
			return t.slice()
		}, t
	}, t.PointCloud = function(t, e) {
		return new Re(t, e)
	}, t.PointCloudMaterial = function(t) {
		return new Ie(t)
	}, t.Vertex = function(t, e, n) {
		return new a(t, e, n)
	}, t.DynamicBufferAttribute = function(t, e) {
		return new dt(t, e).setDynamic(!0)
	}, t.Int8Attribute = function(t, e) {
		return new mt(t, e)
	}, t.Uint8Attribute = function(t, e) {
		return new gt(t, e)
	}, t.Uint8ClampedAttribute = function(t, e) {
		return new vt(t, e)
	}, t.Int16Attribute = function(t, e) {
		return new _t(t, e)
	}, t.Uint16Attribute = function(t, e) {
		return new yt(t, e)
	}, t.Int32Attribute = function(t, e) {
		return new xt(t, e)
	}, t.Uint32Attribute = function(t, e) {
		return new bt(t, e)
	}, t.Float32Attribute = function(t, e) {
		return new wt(t, e)
	}, t.Float64Attribute = function(t, e) {
		return new Mt(t, e)
	}, t.ClosedSplineCurve3 = Ii, t.SplineCurve3 = Ri, t.Spline = Oi, t.Ar = function(t) {
		return new Gi(t)
	}, t.BoundingBr = function(t, e) {
		return new bi(t, e)
	}, t.EdgesHelper = function(t, e) {
		return new Ce(new je(t.geometry), new Ae({
			color: void 0 !== e ? e : 16777215
		}))
	}, t.WireframeHelper = function(t, e) {
		return new Ce(new Ue(t.geometry), new Ae({
			color: void 0 !== e ? e : 16777215
		}))
	}, t.XHRLoader = function(t) {
		return new sn(t)
	}, t.BinaryTextureLoader = function(t) {
		return new cn(t)
	}, t.GeometryUtils = _o, t.ImageUtils = yo, t.Projector = function() {
		this.projectVector = function(t, e) {
			t.project(e)
		}, this.unprojectVector = function(t, e) {
			t.unproject(e)
		}, this.pickingRay = function() {}
	}, Object.defineProperty(t, "__esModule", {
		value: !0
	})
});
var G_0, G_1, G_2, G_3, G_4, G_5, G_6, G_7 = !0,
	G_8 = [],
	G_9 = [],
	G_92 = [],
	G_54 = [],
	G_10 = [],
	G_11 = [],
	G_12 = [],
	G_13, G_18, G_14, G_15, G_16, G_17 = !0,
	G_19 = !1,
	G_20 = !1,
	G_21 = !1,
	G_55 = !1,
	G_22 = !1,
	G_23 = !0,
	G_24 = !1,
	G_25 = !1,
	G_26 = !0,
	G_27 = 0,
	G_28 = !0,
	G_29 = 11584734,
	G_30, G_31, G_32, G_34, G_35, G_36, G_53, G_38, G_39, G_40, G_41 = 0,
	G_42 = 0,
	G_43 = 0,
	G_44 = [],
	G_45 = [],
	G_46 = [],
	G_47 = [],
	G_48, G_50 = [],
	G_51 = [],
	G_49 = 0,
	G_52 = 1e3,
	G_56 = 1,
	G_58 = (new Date).getTime(),
	mytime = 0,
	jsPathstr = document.scripts;
jsPathstr = jsPathstr[jsPathstr.length - 1].src.substring(0, jsPathstr[jsPathstr.length - 1].src.lastIndexOf("/") + 1), Date.prototype.Format = function(t) {
		var e = {
			"M+": this.getMonth() + 1,
			"d+": this.getDate(),
			"h+": this.getHours(),
			"m+": this.getMinutes(),
			"s+": this.getSeconds(),
			"q+": Math.floor((this.getMonth() + 3) / 3),
			S: this.getMilliseconds()
		};
		/(y+)/.test(t) && (t = t.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length)));
		for(var n in e) new RegExp("(" + n + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? e[n] : ("00" + e[n]).substr(("" + e[n]).length)));
		return t
	},
	function(t, e) {
		"object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : t.ES6Promise = e()
	}(this, function() {
		"use strict";

		function t(t) {
			var e = typeof t;
			return null !== t && ("object" === e || "function" === e)
		}

		function e(t) {
			return "function" == typeof t
		}

		function n() {
			return void 0 !== N ? function() {
				N(r)
			} : i()
		}

		function i() {
			var t = setTimeout;
			return function() {
				return t(r, 1)
			}
		}

		function r() {
			for(var t = 0; t < O; t += 2)(0, j[t])(j[t + 1]), j[t] = void 0, j[t + 1] = void 0;
			O = 0
		}

		function a(t, e) {
			var n = arguments,
				i = this,
				r = new this.constructor(s);
			void 0 === r[W] && E(r);
			var a = i._state;
			return a ? function() {
				var t = n[a - 1];
				z(function() {
					return M(a, r, t, i._result)
				})
			}() : y(i, r, t, e), r
		}

		function o(t) {
			var e = this;
			if(t && "object" == typeof t && t.constructor === e) return t;
			var n = new e(s);
			return m(n, t), n
		}

		function s() {}

		function l() {
			return new TypeError("You cannot resolve a promise with itself")
		}

		function c() {
			return new TypeError("A promises callback cannot return that same promise.")
		}

		function h(t) {
			try {
				return t.then
			} catch(t) {
				return Z.error = t, Z
			}
		}

		function u(t, e, n, i) {
			try {
				t.call(e, n, i)
			} catch(t) {
				return t
			}
		}

		function f(t, e, n) {
			z(function(t) {
				var i = !1,
					r = u(n, e, function(n) {
						i || (i = !0, e !== n ? m(t, n) : v(t, n))
					}, function(e) {
						i || (i = !0, _(t, e))
					}, "Settle: " + (t._label || " unknown promise"));
				!i && r && (i = !0, _(t, r))
			}, t)
		}

		function p(t, e) {
			e._state === Y ? v(t, e._result) : e._state === q ? _(t, e._result) : y(e, void 0, function(e) {
				return m(t, e)
			}, function(e) {
				return _(t, e)
			})
		}

		function d(t, n, i) {
			n.constructor === t.constructor && i === a && n.constructor.resolve === o ? p(t, n) : i === Z ? (_(t, Z.error), Z.error = null) : void 0 === i ? v(t, n) : e(i) ? f(t, n, i) : v(t, n)
		}

		function m(e, n) {
			e === n ? _(e, l()) : t(n) ? d(e, n, h(n)) : v(e, n)
		}

		function g(t) {
			t._onerror && t._onerror(t._result), x(t)
		}

		function v(t, e) {
			t._state === X && (t._result = e, t._state = Y, 0 !== t._subscribers.length && z(x, t))
		}

		function _(t, e) {
			t._state === X && (t._state = q, t._result = e, z(g, t))
		}

		function y(t, e, n, i) {
			var r = t._subscribers,
				a = r.length;
			t._onerror = null, r[a] = e, r[a + Y] = n, r[a + q] = i, 0 === a && t._state && z(x, t)
		}

		function x(t) {
			var e = t._subscribers,
				n = t._state;
			if(0 !== e.length) {
				for(var i = void 0, r = void 0, a = t._result, o = 0; o < e.length; o += 3) i = e[o], r = e[o + n], i ? M(n, i, r, a) : r(a);
				t._subscribers.length = 0
			}
		}

		function b() {
			this.error = null
		}

		function w(t, e) {
			try {
				return t(e)
			} catch(t) {
				return J.error = t, J
			}
		}

		function M(t, n, i, r) {
			var a = e(i),
				o = void 0,
				s = void 0,
				l = void 0,
				h = void 0;
			if(a) {
				if(o = w(i, r), o === J ? (h = !0, s = o.error, o.error = null) : l = !0, n === o) return void _(n, c())
			} else o = r, l = !0;
			n._state !== X || (a && l ? m(n, o) : h ? _(n, s) : t === Y ? v(n, o) : t === q && _(n, o))
		}

		function S(t, e) {
			try {
				e(function(e) {
					m(t, e)
				}, function(e) {
					_(t, e)
				})
			} catch(e) {
				_(t, e)
			}
		}

		function G() {
			return K++
		}

		function E(t) {
			t[W] = K++, t._state = void 0, t._result = void 0, t._subscribers = []
		}

		function T(t, e) {
			this._instanceConstructor = t, this.promise = new t(s), this.promise[W] || E(this.promise), R(e) ? (this.length = e.length, this._remaining = e.length, this._result = new Array(this.length), 0 === this.length ? v(this.promise, this._result) : (this.length = this.length || 0, this._enumerate(e), 0 === this._remaining && v(this.promise, this._result))) : _(this.promise, A())
		}

		function A() {
			return new Error("Array Methods must be provided an Array")
		}

		function L() {
			throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")
		}

		function C() {
			throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")
		}

		function P(t) {
			this[W] = G(), this._result = this._state = void 0, this._subscribers = [], s !== t && ("function" != typeof t && L(), this instanceof P ? S(this, t) : C())
		}
		var I = void 0,
			R = I = Array.isArray ? Array.isArray : function(t) {
				return "[object Array]" === Object.prototype.toString.call(t)
			},
			O = 0,
			N = void 0,
			D = void 0,
			z = function(t, e) {
				j[O] = t, j[O + 1] = e, 2 === (O += 2) && (D ? D(r) : H())
			},
			U = "undefined" != typeof window ? window : void 0,
			F = U || {},
			k = F.MutationObserver || F.WebKitMutationObserver,
			B = "undefined" == typeof self && "undefined" != typeof process && "[object process]" === {}.toString.call(process),
			V = "undefined" != typeof Uint8ClampedArray && "undefined" != typeof importScripts && "undefined" != typeof MessageChannel,
			j = new Array(1e3),
			H = void 0;
		H = B ? function() {
			return process.nextTick(r)
		} : k ? function() {
			var t = 0,
				e = new k(r),
				n = document.createTextNode("");
			return e.observe(n, {
					characterData: !0
				}),
				function() {
					n.data = t = ++t % 2
				}
		}() : V ? function() {
			var t = new MessageChannel;
			return t.port1.onmessage = r,
				function() {
					return t.port2.postMessage(0)
				}
		}() : void 0 === U && "function" == typeof require ? function() {
			try {
				var t = require("vertx");
				return N = t.runOnLoop || t.runOnContext, n()
			} catch(t) {
				return i()
			}
		}() : i();
		var W = Math.random().toString(36).substring(16),
			X = void 0,
			Y = 1,
			q = 2,
			Z = new b,
			J = new b,
			K = 0;
		return T.prototype._enumerate = function(t) {
			for(var e = 0; this._state === X && e < t.length; e++) this._eachEntry(t[e], e)
		}, T.prototype._eachEntry = function(t, e) {
			var n = this._instanceConstructor,
				i = n.resolve;
			if(i === o) {
				var r = h(t);
				if(r === a && t._state !== X) this._settledAt(t._state, e, t._result);
				else if("function" != typeof r) this._remaining--, this._result[e] = t;
				else if(n === P) {
					var l = new n(s);
					d(l, t, r), this._willSettleAt(l, e)
				} else this._willSettleAt(new n(function(e) {
					return e(t)
				}), e)
			} else this._willSettleAt(i(t), e)
		}, T.prototype._settledAt = function(t, e, n) {
			var i = this.promise;
			i._state === X && (this._remaining--, t === q ? _(i, n) : this._result[e] = n), 0 === this._remaining && v(i, this._result)
		}, T.prototype._willSettleAt = function(t, e) {
			var n = this;
			y(t, void 0, function(t) {
				return n._settledAt(Y, e, t)
			}, function(t) {
				return n._settledAt(q, e, t)
			})
		}, P.all = function(t) {
			return new T(this, t).promise
		}, P.race = function(t) {
			var e = this;
			return new e(R(t) ? function(n, i) {
				for(var r = t.length, a = 0; a < r; a++) e.resolve(t[a]).then(n, i)
			} : function(t, e) {
				return e(new TypeError("You must pass an array to race."))
			})
		}, P.resolve = o, P.reject = function(t) {
			var e = new this(s);
			return _(e, t), e
		}, P._setScheduler = function(t) {
			D = t
		}, P._setAsap = function(t) {
			z = t
		}, P._asap = z, P.prototype = {
			constructor: P,
			then: a,
			catch: function(t) {
				return this.then(null, t)
			}
		}, P.polyfill = function() {
			var t = void 0;
			if("undefined" != typeof global) t = global;
			else if("undefined" != typeof self) t = self;
			else try {
				t = Function("return this")()
			} catch(t) {
				throw new Error("polyfill failed because global object is unavailable in this environment")
			}
			var e = t.Promise;
			if(e) {
				var n = null;
				try {
					n = Object.prototype.toString.call(e.resolve())
				} catch(t) {}
				if("[object Promise]" === n && !e.cast) return
			}
			t.Promise = P
		}, P.Promise = P, P
	}), GLE.Gr = function() {
		function t(t) {
			this.manager = void 0 !== t ? t : GLE.DefaultLr
		}

		function e() {
			var t = {};
			return {
				get: function(e) {
					return t[e]
				},
				add: function(e, n) {
					t[e] = n
				},
				remove: function(e) {
					delete t[e]
				},
				removeAll: function() {
					t = {}
				}
			}
		}

		function n(t) {
			this.name = f.KHR_LIGHTS, this.lights = {};
			var e = (t.extensions && t.extensions[f.KHR_LIGHTS] || {}).lights || {};
			for(var n in e) {
				var i, r = e[n],
					a = (new GLE.Color).fromArray(r.color);
				switch(r.type) {
					case "directional":
						(i = new GLE.Dt(a)).position.set(0, 0, 1);
						break;
					case "point":
						i = new GLE.PointLight(a);
						break;
					case "spot":
						(i = new GLE.SpotLight(a)).position.set(0, 0, 1);
						break;
					case "ambient":
						i = new GLE.AmbientLight(a)
				}
				i && (void 0 !== r.constantAttenuation && (i.intensity = r.constantAttenuation), void 0 !== r.linearAttenuation && (i.distance = 1 / r.linearAttenuation), void 0 !== r.quadraticAttenuation && (i.decay = r.quadraticAttenuation), void 0 !== r.fallOffAngle && (i.angle = r.fallOffAngle), i.name = r.name || "light_" + n, this.lights[n] = i)
			}
		}

		function i(t) {
			this.name = f.KHR_MATERIALS_COMMON
		}

		function r(t) {
			this.name = f.KHR_BINARY_GT, this.content = null, this.body = null;
			var e = new DataView(t, 0, d);
			this.header = {
				magic: l(new Uint8Array(t.slice(0, 4))),
				version: e.getUint32(4, !0),
				length: e.getUint32(8, !0)
			};
			for(var n = new DataView(t, d), i = 0; i < n.byteLength;) {
				var r = n.getUint32(i, !0);
				i += 4;
				var a = n.getUint32(i, !0);
				if(i += 4, a === m.JSON) {
					var o = new Uint8Array(t, d + i, r);
					this.content = l(o)
				} else if(a === m.BIN) {
					var s = d + i;
					this.body = t.slice(s, s + r)
				}
				i += r
			}
		}

		function a() {
			return {
				name: f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS,
				specularGlossinessParams: ["color", "map", "lightMap", "lightMapIntensity", "aoMap", "aoMapIntensity", "emissive", "emissiveIntensity", "emissiveMap", "bumpMap", "bumpScale", "normalMap", "displacementMap", "displacementScale", "displacementBias", "specularMap", "specular", "glossinessMap", "glossiness", "alphaMap", "envMap", "envMapIntensity", "refractionRatio"],
				getMaterialType: function() {
					return GLE.ShaderMaterial
				},
				extendParams: function(t, e, n) {
					var i = e.extensions[this.name],
						r = GLE.ShaderLib.standard,
						a = GLE.UniformsUtils.clone(r.uniforms),
						o = ["#ifdef USE_SPECULARMAP", "\tuniform sampler2D specularMap;", "#endif"].join("\n"),
						s = ["#ifdef USE_GLOSSINESSMAP", "\tuniform sampler2D glossinessMap;", "#endif"].join("\n"),
						l = ["vec3 specularFactor = specular;", "#ifdef USE_SPECULARMAP", "\tvec4 texelSpecular = texture2D( specularMap, vUv );", "\tspecularFactor *= texelSpecular.rgb;", "#endif"].join("\n"),
						c = ["float glossinessFactor = glossiness;", "#ifdef USE_GLOSSINESSMAP", "\tvec4 texelGlossiness = texture2D( glossinessMap, vUv );", "\tglossinessFactor *= texelGlossiness.a;", "#endif"].join("\n"),
						h = ["PhysicalMaterial material;", "material.diffuseColor = diffuseColor.rgb;", "material.specularRoughness = clamp( 1.0 - glossinessFactor, 0.04, 1.0 );", "material.specularColor = specularFactor.rgb;"].join("\n"),
						u = r.fragmentShader.replace("#include <specularmap_fragment>", "").replace("uniform float roughness;", "uniform vec3 specular;").replace("uniform float metalness;", "uniform float glossiness;").replace("#include <roughnessmap_pars_fragment>", o).replace("#include <metalnessmap_pars_fragment>", s).replace("#include <roughnessmap_fragment>", l).replace("#include <metalnessmap_fragment>", c).replace("#include <lights_physical_fragment>", h);
					delete a.roughness, delete a.metalness, delete a.roughnessMap, delete a.metalnessMap, a.specular = {
						value: (new GLE.Color).setHex(1118481)
					}, a.glossiness = {
						value: .5
					}, a.specularMap = {
						value: null
					}, a.glossinessMap = {
						value: null
					}, t.vertexShader = r.vertexShader, t.fragmentShader = u, t.uniforms = a, t.defines = {
						STANDARD: ""
					}, t.color = new GLE.Color(1, 1, 1), t.opacity = 1;
					var f = [];
					if(Array.isArray(i.diffuseFactor)) {
						var p = i.diffuseFactor;
						t.color.fromArray(p), t.opacity = p[3]
					}
					if(void 0 !== i.diffuseTexture && f.push(n.assignTexture(t, "map", i.diffuseTexture.index)), t.emissive = new GLE.Color(0, 0, 0), t.glossiness = void 0 !== i.glossinessFactor ? i.glossinessFactor : 1, t.specular = new GLE.Color(1, 1, 1), Array.isArray(i.specularFactor) && t.specular.fromArray(i.specularFactor), void 0 !== i.specularGlossinessTexture) {
						var d = i.specularGlossinessTexture.index;
						f.push(n.assignTexture(t, "glossinessMap", d)), f.push(n.assignTexture(t, "specularMap", d))
					}
					return Promise.all(f)
				},
				createMaterial: function(t) {
					var e = new GLE.ShaderMaterial({
						defines: t.defines,
						vertexShader: t.vertexShader,
						fragmentShader: t.fragmentShader,
						uniforms: t.uniforms,
						fog: !0,
						lights: !0,
						opacity: t.opacity,
						transparent: t.transparent
					});
					return e.isGTSpecularGlossinessMaterial = !0, e.color = t.color, e.map = void 0 === t.map ? null : t.map, e.lightMap = null, e.lightMapIntensity = 1, e.aoMap = void 0 === t.aoMap ? null : t.aoMap, e.aoMapIntensity = 1, e.emissive = t.emissive, e.emissiveIntensity = 1, e.emissiveMap = void 0 === t.emissiveMap ? null : t.emissiveMap, e.bumpMap = void 0 === t.bumpMap ? null : t.bumpMap, e.bumpScale = 1, e.normalMap = void 0 === t.normalMap ? null : t.normalMap, t.normalScale && (e.normalScale = t.normalScale), e.displacementMap = null, e.displacementScale = 1, e.displacementBias = 0, e.specularMap = void 0 === t.specularMap ? null : t.specularMap, e.specular = t.specular, e.glossinessMap = void 0 === t.glossinessMap ? null : t.glossinessMap, e.glossiness = t.glossiness, e.alphaMap = null, e.envMap = void 0 === t.envMap ? null : t.envMap, e.envMapIntensity = 1, e.refractionRatio = .98, e.extensions.derivatives = !0, e
				},
				cloneMaterial: function(t) {
					var e = t.clone();
					e.isGTSpecularGlossinessMaterial = !0;
					for(var n = this.specularGlossinessParams, i = 0; i < n.length; i++) e[n[i]] = t[n[i]];
					return e
				},
				refreshUniforms: function(t, e, n, i, r, a) {
					var o = r.uniforms,
						s = r.defines;
					o.opacity.value = r.opacity, o.diffuse.value.copy(r.color), o.emissive.value.copy(r.emissive).multiplyScalar(r.emissiveIntensity), o.map.value = r.map, o.specularMap.value = r.specularMap, o.alphaMap.value = r.alphaMap, o.lightMap.value = r.lightMap, o.lightMapIntensity.value = r.lightMapIntensity, o.aoMap.value = r.aoMap, o.aoMapIntensity.value = r.aoMapIntensity;
					var l;
					if(r.map ? l = r.map : r.specularMap ? l = r.specularMap : r.displacementMap ? l = r.displacementMap : r.normalMap ? l = r.normalMap : r.bumpMap ? l = r.bumpMap : r.glossinessMap ? l = r.glossinessMap : r.alphaMap ? l = r.alphaMap : r.emissiveMap && (l = r.emissiveMap), void 0 !== l) {
						l.isWt && (l = l.texture);
						var c, h;
						if(void 0 !== l.matrix) {
							if(!0 === l.matrixAutoUpdate) {
								c = l.offset, h = l.repeat;
								var u = l.rotation,
									f = l.center;
								l.matrix.setUvTransform(c.x, c.y, h.x, h.y, u, f.x, f.y)
							}
							o.uvTransform.value.copy(l.matrix)
						} else c = l.offset, h = l.repeat, o.offsetRepeat.value.set(c.x, c.y, h.x, h.y)
					}
					o.envMap.value = r.envMap, o.envMapIntensity.value = r.envMapIntensity, o.flipEnvMap.value = r.envMap && r.envMap.isCubeTexture ? -1 : 1, o.refractionRatio.value = r.refractionRatio, o.specular.value.copy(r.specular), o.glossiness.value = r.glossiness, o.glossinessMap.value = r.glossinessMap, o.emissiveMap.value = r.emissiveMap, o.bumpMap.value = r.bumpMap, o.normalMap.value = r.normalMap, o.displacementMap.value = r.displacementMap, o.displacementScale.value = r.displacementScale, o.displacementBias.value = r.displacementBias, null !== o.glossinessMap.value && void 0 === s.USE_GLOSSINESSMAP && (s.USE_GLOSSINESSMAP = "", s.USE_ROUGHNESSMAP = ""), null === o.glossinessMap.value && void 0 !== s.USE_GLOSSINESSMAP && (delete s.USE_GLOSSINESSMAP, delete s.USE_ROUGHNESSMAP)
				}
			}
		}

		function o(t, e, n) {
			if(!t) return Promise.resolve();
			var i, r = [];
			if("[object Array]" === Object.prototype.toString.call(t)) {
				i = [];
				for(var a = t.length, o = 0; o < a; o++)(l = e.call(n || this, t[o], o)) && (l instanceof Promise ? l = l.then(function(t, e) {
					i[t] = e
				}.bind(this, o)) : i[o] = l, r.push(l))
			} else {
				i = {};
				for(var s in t)
					if(t.hasOwnProperty(s)) {
						var l = e.call(n || this, t[s], s);
						l && (l instanceof Promise ? l = l.then(function(t, e) {
							i[t] = e
						}.bind(this, s)) : i[s] = l, r.push(l))
					}
			}
			return Promise.all(r).then(function() {
				return i
			})
		}

		function s(t, e) {
			return "string" != typeof t || "" === t ? "" : /^(https?:)?\/\//i.test(t) ? t : /^data:.*,.*$/i.test(t) ? t : /^blob:.*$/i.test(t) ? t : e + t
		}

		function l(t) {
			if(void 0 !== window.TextDecoder) return(new TextDecoder).decode(t);
			for(var e = "", n = 0, i = t.length; n < i; n++) e += String.fromCharCode(t[n]);
			return e
		}

		function c() {
			return G_55 ? new GLE.Mal({
				color: 12369084,
				emissive: 0,
				metalness: 1,
				roughness: 1,
				transparent: !1,
				depthTest: !0,
				side: GLE.FrontSide
			}) : new GLE.MeshStandardMaterial({
				color: 16777215,
				emissive: 0,
				metalness: 1,
				roughness: 1,
				transparent: !1,
				depthTest: !0,
				side: GLE.FrontSide
			})
		}

		function h(t, e, n, i) {
			var r = t.geometry,
				a = t.material,
				o = n.targets,
				s = r.morphAttributes;
			s.position = [], s.normal = [], a.morphTargets = !0;
			for(var l = 0, c = o.length; l < c; l++) {
				var h, u, f = o[l],
					p = "morphTarget" + l;
				if(void 0 !== f.POSITION) {
					h = i.accessors[f.POSITION].clone();
					for(var d = r.attributes.position, m = 0, g = h.count; m < g; m++) h.setXYZ(m, h.getX(m) + d.getX(m), h.getY(m) + d.getY(m), h.getZ(m) + d.getZ(m))
				} else r.attributes.position && (h = r.attributes.position.clone());
				if(void 0 !== h && (h.name = p, s.position.push(h)), void 0 !== f.NORMAL) {
					a.morphNormals = !0, u = i.accessors[f.NORMAL].clone();
					for(var v = r.attributes.normal, m = 0, g = u.count; m < g; m++) u.setXYZ(m, u.getX(m) + v.getX(m), u.getY(m) + v.getY(m), u.getZ(m) + v.getZ(m))
				} else void 0 !== r.attributes.normal && (u = r.attributes.normal.clone());
				void 0 !== u && (u.name = p, s.normal.push(u))
			}
			if(t.updateMorphTargets(), void 0 !== e.weights)
				for(var l = 0, c = e.weights.length; l < c; l++) t.morphTargetInfluences[l] = e.weights[l]
		}

		function u(t, n, i) {
			this.json = t || {}, this.extensions = n || {}, this.options = i || {}, this.cache = new e, this.textureLoader = new GLE.TextureLoader(this.options.manager), this.textureLoader.setCrossOrigin(this.options.crossOrigin), this.fileLoader = new GLE.FileLoader(this.options.manager), this.fileLoader.setResponseType("arraybuffer")
		}
		t.prototype = {
			constructor: t,
			crossOrigin: "Anonymous",
			load: function(t, e, n, i) {
				var r = this,
					a = void 0 !== this.path ? this.path : GLE.Loader.prototype.extractUrlBase(t);
				t.substr(t.lastIndexOf(".") + 1);
				JSZipUtils.getBinaryContent(t, function(n, o) {
					if(n) throw n;
					JSZip.loadAsync(o).then(function(e) {
						var n = t.lastIndexOf("/"),
							i = t.lastIndexOf("."),
							r = t.substr(n + 1, i - 4);
						return e.file(r).async("arraybuffer")
					}).then(function(t) {
						r.parse(t, a, e, i)
					})
				})
			},
			setCrossOrigin: function(t) {
				this.crossOrigin = t
			},
			setPath: function(t) {
				this.path = t
			},
			parse: function(t, e, o, s) {
				var c, h = {};
				if("string" == typeof t) c = t;
				else if(l(new Uint8Array(t, 0, 4)) === p) {
					try {
						h[f.KHR_BINARY_GT] = new r(t)
					} catch(t) {
						return void(s && s(t))
					}
					c = h[f.KHR_BINARY_GT].content
				} else c = l(new Uint8Array(t));
				var d = JSON.parse(c);
				void 0 === d.asset || d.asset.version[0] < 2 || (d.extensionsUsed && (d.extensionsUsed.indexOf(f.KHR_LIGHTS) >= 0 && (h[f.KHR_LIGHTS] = new n(d)), d.extensionsUsed.indexOf(f.KHR_MATERIALS_COMMON) >= 0 && (h[f.KHR_MATERIALS_COMMON] = new i(d)), d.extensionsUsed.indexOf(f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS) >= 0 && (h[f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS] = new a)), new u(d, h, {
					path: e || this.path || "",
					crossOrigin: this.crossOrigin,
					manager: this.manager
				}).parse(function(t, e, n, i) {
					o({
						scene: t,
						scenes: e,
						cameras: n,
						animations: i
					})
				}, s))
			}
		};
		var f = {
			KHR_BINARY_GT: "KHR_binary_glTF",
			KHR_LIGHTS: "KHR_lights",
			KHR_MATERIALS_COMMON: "KHR_materials_common",
			KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS: "KHR_materials_pbrSpecularGlossiness"
		};
		i.prototype.getMaterialType = function(t) {
			switch(t.extensions[this.name].type) {
				case "commonBlinn":
				case "commonPhong":
					return GLE.MeshPhongMaterial;
				case "commonLambert":
					return GLE.MeshLambertMaterial;
				case "commonConstant":
				default:
					return GLE.Mal
			}
		}, i.prototype.extendParams = function(t, e, n) {
			var i = e.extensions[this.name],
				r = [],
				a = [];
			switch(i.type) {
				case "commonBlinn":
				case "commonPhong":
					a.push("diffuseFactor", "diffuseTexture", "specularFactor", "specularTexture", "shininessFactor");
					break;
				case "commonLambert":
					a.push("diffuseFactor", "diffuseTexture")
			}
			var o = {};
			return a.forEach(function(t) {
				void 0 !== i[t] && (o[t] = i[t])
			}), void 0 !== o.diffuseFactor && (t.color = (new GLE.Color).fromArray(o.diffuseFactor), t.opacity = o.diffuseFactor[3]), void 0 !== o.diffuseTexture && r.push(n.assignTexture(t, "map", o.diffuseTexture.index)), void 0 !== o.specularFactor && (t.specular = (new GLE.Color).fromArray(o.specularFactor)), void 0 !== o.specularTexture && r.push(n.assignTexture(t, "specularMap", o.specularTexture.index)), void 0 !== o.shininessFactor && (t.shininess = o.shininessFactor), Promise.all(r)
		};
		var p = "glTF",
			d = 12,
			m = {
				JSON: 1313821514,
				BIN: 5130562
			},
			g = {
				FLOAT: 5126,
				FLOAT_MAT3: 35675,
				FLOAT_MAT4: 35676,
				FLOAT_VEC2: 35664,
				FLOAT_VEC3: 35665,
				FLOAT_VEC4: 35666,
				LINEAR: 9729,
				REPEAT: 10497,
				SAMPLER_2D: 35678,
				POINTS: 0,
				LINES: 1,
				LINE_LOOP: 2,
				LINE_STRIP: 3,
				TRIANGLES: 4,
				TRIANGLE_STRIP: 5,
				TRIANGLE_FAN: 6,
				UNSIGNED_BYTE: 5121,
				UNSIGNED_SHORT: 5123
			},
			v = (Number, GLE.Matrix3, GLE.Matrix4, GLE.Vector2, GLE.Vector3, GLE.Vector4, GLE.Texture, {
				5120: Int8Array,
				5121: Uint8Array,
				5122: Int16Array,
				5123: Uint16Array,
				5125: Uint32Array,
				5126: Float32Array
			}),
			_ = {
				9728: GLE.Nr,
				9729: GLE.LinearFilter,
				9984: GLE.NearestMipMapNr,
				9985: GLE.LinearMipMapNr,
				9986: GLE.NearestMipMapLinearFilter,
				9987: GLE.LinearMipMapLinearFilter
			},
			y = {
				33071: GLE.ClampToEdgeWrapping,
				33648: GLE.MirroredRepeatWrapping,
				10497: GLE.RepeatWrapping
			},
			x = {
				6406: GLE.AlphaFormat,
				6407: GLE.RGBFormat,
				6408: GLE.RGBAFormat,
				6409: GLE.LuminanceFormat,
				6410: GLE.LuminanceAlphaFormat
			},
			b = {
				5121: GLE.UnsignedByteType,
				32819: GLE.UnsignedShort4444Type,
				32820: GLE.UnsignedShort5551Type,
				33635: GLE.UnsignedShort565Type
			},
			w = (GLE.BackSide, GLE.FrontSide, GLE.NeverDepth, GLE.LessDepth, GLE.EqualDepth, GLE.LessEqualDepth, GLE.GreaterEqualDepth, GLE.NotEqualDepth, GLE.GreaterEqualDepth, GLE.AlwaysDepth, GLE.AddEquation, GLE.SubtractEquation, GLE.ReverseSubtractEquation, GLE.ZeroFactor, GLE.OneFactor, GLE.SrcColorFactor, GLE.OneMinusSrcColorFactor, GLE.SrcAlphaFactor, GLE.OneMinusSrcAlphaFactor, GLE.DstAlphaFactor, GLE.OneMinusDstAlphaFactor, GLE.DstColorFactor, GLE.OneMinusDstColorFactor, GLE.SrcAlphaSaturateFactor, {
				SCALAR: 1,
				VEC2: 2,
				VEC3: 3,
				VEC4: 4,
				MAT2: 4,
				MAT3: 9,
				MAT4: 16
			}),
			M = {
				scale: "scale",
				translation: "position",
				rotation: "quaternion",
				weights: "morphTargetInfluences"
			},
			S = {
				CATMULLROMSPLINE: GLE.InterpolateSmooth,
				CUBICSPLINE: GLE.InterpolateSmooth,
				LINEAR: GLE.InterpolateLinear,
				STEP: GLE.InterpolateDiscrete
			},
			G = {
				OPAQUE: "OPAQUE",
				MASK: "MASK",
				BLEND: "BLEND"
			};
		return u.prototype._withDependencies = function(t) {
			for(var e = {}, n = 0; n < t.length; n++) {
				var i = t[n],
					r = "load" + i.charAt(0).toUpperCase() + i.slice(1),
					a = this.cache.get(i);
				if(void 0 !== a) e[i] = a;
				else if(this[r]) {
					var s = this[r]();
					this.cache.add(i, s), e[i] = s
				}
			}
			return o(e, function(t) {
				return t
			})
		}, u.prototype.parse = function(t, e) {
			var n = this.json,
				i = this;
			this.cache.removeAll(), this._withDependencies(["scenes", "animations"]).then(function(r) {
				var a = r.scenes || [],
					o = a[n.scene || 0],
					s = r.animations || [];
				i.getDependencies("camera").then(function(e) {
					t(o, a, e, s)
				}).catch(e)
			}).catch(e)
		}, u.prototype.getDependency = function(t, e) {
			var n = t + ":" + e,
				i = this.cache.get(n);
			return i || (i = this["load" + t.charAt(0).toUpperCase() + t.slice(1)](e), this.cache.add(n, i)), i
		}, u.prototype.getDependencies = function(t) {
			var e = this,
				n = this.json[t + "s"] || [];
			return Promise.all(n.map(function(n, i) {
				return e.getDependency(t, i)
			}))
		}, u.prototype.loadBuffer = function(t) {
			var e = this.json.buffers[t],
				n = this.fileLoader;
			if(void 0 === e.uri && 0 === t) return Promise.resolve(this.extensions[f.KHR_BINARY_GT].body);
			var i = this.options;
			return new Promise(function(t, r) {
				n.load(s(e.uri, i.path), t, void 0, function() {
					r()
				})
			})
		}, u.prototype.loadBufferView = function(t) {
			var e = this.json.bufferViews[t];
			return this.getDependency("buffer", e.buffer).then(function(t) {
				var n = e.byteLength || 0,
					i = e.byteOffset || 0;
				return t.slice(i, i + n)
			})
		}, u.prototype.loadAccessors = function() {
			var t = this,
				e = this.json;
			return o(e.accessors, function(n) {
				return t.getDependency("bufferView", n.bufferView).then(function(t) {
					var i, r = w[n.type],
						a = v[n.componentType],
						o = a.BYTES_PER_ELEMENT,
						s = o * r,
						l = e.bufferViews[n.bufferView].byteStride,
						c = !0 === n.normalized;
					if(l && l !== s) {
						i = new a(t);
						var h = new GLE.InterleavedBuffer(i, l / o);
						return new GLE.InterleavedBufferAttribute(h, r, n.byteOffset / o, c)
					}
					return i = new a(t, n.byteOffset, n.count * r), new GLE.BufferAttribute(i, r, c)
				})
			})
		}, u.prototype.loadTexture = function(t) {
			var e = this,
				n = this.json,
				i = this.options,
				r = this.textureLoader,
				a = window.URL || window.webkitURL,
				o = n.textures[t],
				l = n.images[o.source],
				c = l.uri,
				h = !1;
			return void 0 !== l.bufferView && (c = e.getDependency("bufferView", l.bufferView).then(function(t) {
				h = !0;
				var e = new Blob([t], {
					type: l.mimeType
				});
				return c = a.createObjectURL(e)
			})), Promise.resolve(c).then(function(t) {
				var e = GLE.Loader.Handlers.get(t) || r;
				return new Promise(function(n, r) {
					e.load(s(t, i.path), n, void 0, r)
				})
			}).then(function(t) {
				!0 === h && a.revokeObjectURL(c), t.flipY = !1, void 0 !== o.name && (t.name = o.name), t.format = void 0 !== o.format ? x[o.format] : GLE.RGBAFormat, t.type = void 0 !== o.type ? b[o.type] : GLE.UnsignedByteType;
				var e = (n.samplers || {})[o.sampler] || {};
				return t.magFilter = _[e.magFilter] || GLE.LinearFilter, t.minFilter = _[e.minFilter] || GLE.LinearMipMapLinearFilter, t.wrapS = y[e.wrapS] || GLE.RepeatWrapping, t.wrapT = y[e.wrapT] || GLE.RepeatWrapping, t
			})
		}, u.prototype.assignTexture = function(t, e, n) {
			return this.getDependency("texture", n).then(function(n) {
				t[e] = n
			})
		}, u.prototype.loadMaterials = function() {
			var t = this,
				e = this.json,
				n = this.extensions;
			return o(e.materials, function(e) {
				var i, r = {},
					a = e.extensions || {},
					o = [];
				if(a[f.KHR_MATERIALS_COMMON]) {
					var s = n[f.KHR_MATERIALS_COMMON];
					i = s.getMaterialType(e), o.push(s.extendParams(r, e, t))
				} else if(a[f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS]) {
					var l = n[f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS];
					i = l.getMaterialType(e), o.push(l.extendParams(r, e, t))
				} else if(void 0 !== e.pbrMetallicRoughness) {
					i = GLE.MeshStandardMaterial;
					var c = e.pbrMetallicRoughness;
					if(r.color = new GLE.Color(1, 1, 1), r.opacity = 1, Array.isArray(c.baseColorFactor)) {
						var h = c.baseColorFactor;
						r.color.fromArray(h), r.opacity = h[3]
					}
					if(void 0 !== c.baseColorTexture && o.push(t.assignTexture(r, "map", c.baseColorTexture.index)), r.metalness = void 0 !== c.metallicFactor ? c.metallicFactor : 1, r.roughness = void 0 !== c.roughnessFactor ? c.roughnessFactor : 1, void 0 !== c.metallicRoughnessTexture) {
						var u = c.metallicRoughnessTexture.index;
						o.push(t.assignTexture(r, "metalnessMap", u)), o.push(t.assignTexture(r, "roughnessMap", u))
					}
				} else i = GLE.MeshPhongMaterial;
				!0 === e.doubleSided && (r.side = GLE.DoubleSide);
				var p = e.alphaMode || G.OPAQUE;
				return p !== G.OPAQUE ? (r.transparent = !0, p === G.MASK && (r.alphaTest = void 0 !== e.alphaCutoff ? e.alphaCutoff : .5)) : r.transparent = !1, void 0 !== e.normalTexture && (o.push(t.assignTexture(r, "normalMap", e.normalTexture.index)), r.normalScale = new GLE.Vector2(1, 1), void 0 !== e.normalTexture.scale && r.normalScale.set(e.normalTexture.scale, e.normalTexture.scale)), void 0 !== e.occlusionTexture && (o.push(t.assignTexture(r, "aoMap", e.occlusionTexture.index)), void 0 !== e.occlusionTexture.strength && (r.aoMapIntensity = e.occlusionTexture.strength)), void 0 !== e.emissiveFactor && (i === GLE.Mal ? r.color = (new GLE.Color).fromArray(e.emissiveFactor) : r.emissive = (new GLE.Color).fromArray(e.emissiveFactor)), void 0 !== e.emissiveTexture && (i === GLE.Mal ? o.push(t.assignTexture(r, "map", e.emissiveTexture.index)) : o.push(t.assignTexture(r, "emissiveMap", e.emissiveTexture.index))), Promise.all(o).then(function() {
					var t;
					return t = i === GLE.ShaderMaterial ? n[f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS].createMaterial(r) : new i(r), void 0 !== e.name && (t.name = e.name), t.normalScale && (t.normalScale.x = -t.normalScale.x), t.map && (t.map.encoding = GLE.sRGBEncoding), t.emissiveMap && (t.emissiveMap.encoding = GLE.sRGBEncoding), e.extras && (t.userData = e.extras), t
				})
			})
		}, u.prototype.loadGeometries = function(t) {
			return this._withDependencies(["accessors"]).then(function(e) {
				return o(t, function(t) {
					var n = new GLE.BufferGeometry,
						i = t.attributes;
					for(var r in i) {
						var a = i[r];
						if(void 0 === a) return;
						var o = e.accessors[a];
						switch(r) {
							case "POSITION":
								n.addAttribute("position", o);
								break;
							case "NORMAL":
								n.addAttribute("normal", o);
								break;
							case "TEXCOORD_0":
							case "TEXCOORD0":
							case "TEXCOORD":
								n.addAttribute("uv", o);
								break;
							case "TEXCOORD_1":
								n.addAttribute("uv2", o);
								break;
							case "COLOR_0":
							case "COLOR0":
							case "COLOR":
								n.addAttribute("color", o);
								break;
							case "WEIGHTS_0":
							case "WEIGHT":
								n.addAttribute("skinWeight", o);
								break;
							case "JOINTS_0":
							case "JOINT":
								n.addAttribute("skinIndex", o)
						}
					}
					return void 0 !== t.indices && n.setIndex(e.accessors[t.indices]), n
				})
			})
		}, u.prototype.loadMeshes = function() {
			var t = this,
				e = this.json,
				n = this.extensions;
			return this._withDependencies(["accessors", "materials"]).then(function(i) {
				return o(e.meshes, function(e, r) {
					var a = new GLE.Group,
						o = e.primitives || [];
					return t.loadGeometries(o).then(function(t) {
						for(var s = 0; s < o.length; s++) {
							var l = o[s],
								u = t[s],
								p = void 0 === l.material ? c() : i.materials[l.material];
							p.aoMap && void 0 === u.attributes.uv2 && void 0 !== u.attributes.uv && u.addAttribute("uv2", new GLE.BufferAttribute(u.attributes.uv.array, 2));
							var d = void 0 !== u.attributes.color,
								m = void 0 === u.attributes.normal;
							(d || m) && (p = p.isGTSpecularGlossinessMaterial ? n[f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS].cloneMaterial(p) : p.clone()), d && (p.vertexColors = GLE.VertexColors, p.needsUpdate = !0), m && (p.flatShading = !0);
							var v;
							if(l.mode === g.TRIANGLES || void 0 === l.mode ? v = new GLE.Mesh(u, p) : l.mode === g.TRIANGLE_STRIP ? (v = new GLE.Mesh(u, p)).drawMode = GLE.TriangleStripDrawMode : l.mode === g.TRIANGLE_FAN ? (v = new GLE.Mesh(u, p)).drawMode = GLE.TriangleFanDrawMode : l.mode === g.LINES ? v = new GLE.LineSegments(u, p) : l.mode === g.LINE_STRIP ? v = new GLE.Line(u, p) : l.mode === g.LINE_LOOP ? v = new GLE.LineLoop(u, p) : l.mode === g.POINTS && (v = new GLE.Points(u, p)), v.name = e.name || "mesh_" + r, void 0 !== l.targets && h(v, e, l, i), l.extras && (v.userData = l.extras), !(o.length > 1)) return v;
							v.name += "_" + s, a.add(v)
						}
						return a
					})
				})
			})
		}, u.prototype.loadCamera = function(t) {
			var e, n = this.json.cameras[t],
				i = n[n.type];
			if(i) {
				if("perspective" === n.type) {
					var r = i.aspectRatio || 1,
						a = i.yfov * r;
					e = new GLE.Pa(GLE.Math.radToDeg(a), r, i.znear || 1, i.zfar || 2e6)
				} else "orthographic" === n.type && (e = new GLE.OrthographicCamera(i.xmag / -2, i.xmag / 2, i.ymag / 2, i.ymag / -2, i.znear, i.zfar));
				return void 0 !== n.name && (e.name = n.name), n.extras && (e.userData = n.extras), Promise.resolve(e)
			}
		}, u.prototype.loadSkins = function() {
			var t = this.json;
			return this._withDependencies(["accessors"]).then(function(e) {
				return o(t.skins, function(t) {
					return {
						joints: t.joints,
						inverseBindMatrices: e.accessors[t.inverseBindMatrices]
					}
				})
			})
		}, u.prototype.loadAnimations = function() {
			var t = this.json;
			return this._withDependencies(["accessors", "nodes"]).then(function(e) {
				return o(t.animations, function(t, n) {
					for(var i = [], r = 0; r < t.channels.length; r++) {
						var a = t.channels[r],
							o = t.samplers[a.sampler];
						if(o) {
							var s = a.target,
								l = void 0 !== s.node ? s.node : s.id,
								c = void 0 !== t.parameters ? t.parameters[o.input] : o.input,
								h = void 0 !== t.parameters ? t.parameters[o.output] : o.output,
								u = e.accessors[c],
								f = e.accessors[h],
								p = e.nodes[l];
							if(p) {
								p.updateMatrix(), p.matrixAutoUpdate = !0;
								var d;
								switch(M[s.path]) {
									case M.weights:
										d = GLE.NumberKeyframeTrack;
										break;
									case M.rotation:
										d = GLE.QuaternionKeyframeTrack;
										break;
									case M.position:
									case M.scale:
									default:
										d = GLE.VectorKeyframeTrack
								}
								var m = p.name ? p.name : p.uuid,
									g = void 0 !== o.interpolation ? S[o.interpolation] : GLE.InterpolateLinear,
									v = [];
								M[s.path] === M.weights ? p.traverse(function(t) {
									!0 === t.isMesh && !0 === t.material.morphTargets && v.push(t.name ? t.name : t.uuid)
								}) : v.push(m);
								for(var _ = 0, y = v.length; _ < y; _++) i.push(new d(v[_] + "." + M[s.path], GLE.AnimationUtils.arraySlice(u.array, 0), GLE.AnimationUtils.arraySlice(f.array, 0), g))
							}
						}
					}
					l = void 0 !== t.name ? t.name : "animation_" + n;
					return new GLE.AnimationClip(l, void 0, i)
				})
			})
		}, u.prototype.loadNodes = function() {
			for(var t = this.json, e = this.extensions, n = this, i = t.nodes || [], r = t.skins || [], a = {}, s = {}, l = 0; l < r.length; l++)
				for(var c = r[l].joints, h = 0; h < c.length; ++h) i[c[h]].isBone = !0;
			for(var u = 0; u < i.length; u++) {
				var p = i[u];
				void 0 !== p.mesh && (void 0 === a[p.mesh] && (a[p.mesh] = s[p.mesh] = 0), a[p.mesh]++)
			}
			return n._withDependencies(["meshes", "skins", "cameras"]).then(function(i) {
				return o(t.nodes, function(t) {
					if(!0 === t.isBone) return new GLE.Bone;
					if(void 0 !== t.mesh) {
						var r = i.meshes[t.mesh].clone();
						return a[t.mesh] > 1 && (r.name += "_instance_" + s[t.mesh]++), r
					}
					return void 0 !== t.camera ? n.getDependency("camera", t.camera) : t.extensions && t.extensions[f.KHR_LIGHTS] && void 0 !== t.extensions[f.KHR_LIGHTS].light ? e[f.KHR_LIGHTS].lights[t.extensions[f.KHR_LIGHTS].light] : new GLE.Object3D
				}).then(function(e) {
					return o(e, function(n, r) {
						var a = t.nodes[r];
						if(void 0 !== a.name && (n.name = GLE.PropertyBinding.sanitizeNodeName(a.name)), a.extras && (n.userData = a.extras), void 0 !== a.matrix) {
							var o = new GLE.Matrix4;
							o.fromArray(a.matrix), n.applyMatrix(o)
						} else void 0 !== a.translation && n.position.fromArray(a.translation), void 0 !== a.rotation && n.quaternion.fromArray(a.rotation), void 0 !== a.scale && n.scale.fromArray(a.scale);
						if(void 0 !== a.skin) {
							for(var s = [], l = n.children.length > 0 ? n.children : [n], c = 0; c < l.length; c++) {
								var h = l[c],
									u = i.skins[a.skin],
									f = h.geometry,
									p = h.material;
								p.skinning = !0;
								var d = new GLE.SkinnedMesh(f, p);
								d.morphTargetInfluences = h.morphTargetInfluences, d.userData = h.userData, d.name = h.name;
								for(var m = [], g = [], v = 0, _ = u.joints.length; v < _; v++) {
									var y = u.joints[v],
										x = e[y];
									if(x) {
										m.push(x);
										var b = u.inverseBindMatrices.array,
											w = (new GLE.Matrix4).fromArray(b, 16 * v);
										g.push(w)
									}
								}
								d.bind(new GLE.Skeleton(m, g), d.matrixWorld), s.push(d)
							}
							n.children.length > 0 ? (n.remove.apply(n, n.children), n.add.apply(n, s)) : n = s[0]
						}
						return n
					})
				})
			})
		}, u.prototype.loadScenes = function() {
			function t(n, i, r) {
				var a = r[n];
				i.add(a);
				var o = e.nodes[n];
				if(o.children)
					for(var s = o.children, l = 0, c = s.length; l < c; l++) t(s[l], a, r)
			}
			var e = this.json,
				n = this.extensions;
			return this._withDependencies(["nodes"]).then(function(i) {
				return o(e.scenes, function(e) {
					var r = new GLE.Scene;
					void 0 !== e.name && (r.name = e.name), e.extras && (r.userData = e.extras);
					for(var a = e.nodes || [], o = 0, s = a.length; o < s; o++) t(a[o], r, i.nodes);
					if(r.traverse(function(t) {
							t.material && t.material.isGTSpecularGlossinessMaterial && (t.onBeforeRender = n[f.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS].refreshUniforms)
						}), e.extensions && e.extensions[f.KHR_LIGHTS] && void 0 !== e.extensions[f.KHR_LIGHTS].light) {
						var l = n[f.KHR_LIGHTS].lights;
						r.add(l[e.extensions[f.KHR_LIGHTS].light])
					}
					return r
				})
			})
		}, t
	}();
var Stats = function() {
	function t(t) {
		return i.appendChild(t.dom), t
	}

	function e(t) {
		for(var e = 0; e < i.children.length; e++) i.children[e].style.display = e === t ? "block" : "none";
		n = t
	}
	var n = 0,
		i = document.createElement("div");
	i.style.cssText = "position:fixed;top:0;left:0;cursor:pointer;opacity:0.9;z-index:10000", i.addEventListener("click", function(t) {
		t.preventDefault(), e(++n % i.children.length)
	}, !1);
	var r = (performance || Date).now(),
		a = r,
		o = 0,
		s = t(new Stats.Panel("FPS", "#0ff", "#002")),
		l = t(new Stats.Panel("MS", "#0f0", "#020"));
	if(self.performance && self.performance.memory) var c = t(new Stats.Panel("MB", "#f08", "#201"));
	return e(0), {
		REVISION: 16,
		dom: i,
		addPanel: t,
		showPanel: e,
		begin: function() {
			r = (performance || Date).now()
		},
		end: function() {
			o++;
			var t = (performance || Date).now();
			if(l.update(t - r, 200), t > a + 1e3 && (s.update(1e3 * o / (t - a), 100), a = t, o = 0, c)) {
				var e = performance.memory;
				c.update(e.usedJSHeapSize / 1048576, e.jsHeapSizeLimit / 1048576)
			}
			return t
		},
		update: function() {
			r = this.end()
		},
		domElement: i,
		setMode: e
	}
};
Stats.Panel = function(t, e, n) {
	var i = 1 / 0,
		r = 0,
		a = Math.round,
		o = a(window.devicePixelRatio || 1),
		s = 80 * o,
		l = 48 * o,
		c = 3 * o,
		h = 2 * o,
		u = 3 * o,
		f = 15 * o,
		p = 74 * o,
		d = 30 * o,
		m = document.createElement("canvas");
	m.width = s, m.height = l, m.style.cssText = "width:80px;height:48px";
	var g = m.getContext("2d");
	return g.font = "bold " + 9 * o + "px Helvetica,Arial,sans-serif", g.textBaseline = "top", g.fillStyle = n, g.fillRect(0, 0, s, l), g.fillStyle = e, g.fillText(t, c, h), g.fillRect(u, f, p, d), g.fillStyle = n, g.globalAlpha = .9, g.fillRect(u, f, p, d), {
		dom: m,
		update: function(l, v) {
			i = Math.min(i, l), r = Math.max(r, l), g.fillStyle = n, g.globalAlpha = 1, g.fillRect(0, 0, s, f), g.fillStyle = e, g.fillText(a(l) + " " + t + " (" + a(i) + "-" + a(r) + ")", c, h), g.drawImage(m, u + o, f, p - o, d, u, f, p - o, d), g.fillRect(u + p - o, f, o, d), g.fillStyle = n, g.globalAlpha = .9, g.fillRect(u + p - o, f, o, a((1 - l / v) * d))
		}
	}
}, "object" == typeof module && (module.exports = Stats);
var Canvas2Image = function() {
	function t(t, e, n) {
		var i = t.width,
			r = t.height;
		void 0 == e && (e = i), void 0 == n && (n = r);
		var a = document.createElement("canvas"),
			o = a.getContext("2d");
		return a.width = e, a.height = n, o.drawImage(t, 0, 0, i, r, 0, 0, e, n), a
	}

	function e(e, n, i, r) {
		return(e = t(e, i, r)).toDataURL(n)
	}

	function n(t) {
		document.location.href = t
	}

	function i(t) {
		var e = document.createElement("img");
		return e.src = t, e
	}

	function r(t) {
		return "image/" + (t = t.toLowerCase().replace(/jpg/i, "jpeg")).match(/png|jpeg|bmp|gif/)[0]
	}

	function a(t) {
		if(!window.btoa) throw "btoa undefined";
		var e = "";
		if("string" == typeof t) e = t;
		else
			for(var n = 0; n < t.length; n++) e += String.fromCharCode(t[n]);
		return btoa(e)
	}

	function o(t) {
		var e = t.width,
			n = t.height;
		return t.getContext("2d").getImageData(0, 0, e, n)
	}

	function s(t, e) {
		return "data:" + e + ";base64," + t
	}
	var l = function() {
			var t = document.createElement("canvas"),
				e = t.getContext("2d");
			return {
				canvas: !!e,
				imageData: !!e.getImageData,
				dataURL: !!t.toDataURL,
				btoa: !!window.btoa
			}
		}(),
		c = function(t, e) {
			var n = document.createElementNS("http://www.w3.org/1999/xhtml", "a");
			n.href = t, n.download = e;
			var i = document.createEvent("MouseEvents");
			i.initMouseEvent("click", !0, !1, window, 0, 0, 0, 0, 0, !1, !1, !1, !1, 0, null), n.dispatchEvent(i)
		},
		h = function(t) {
			var e = t.width,
				n = t.height,
				i = e * n * 3,
				r = i + 54,
				o = [66, 77, 255 & r, r >> 8 & 255, r >> 16 & 255, r >> 24 & 255, 0, 0, 0, 0, 54, 0, 0, 0],
				s = [40, 0, 0, 0, 255 & e, e >> 8 & 255, e >> 16 & 255, e >> 24 & 255, 255 & n, n >> 8 & 255, n >> 16 & 255, n >> 24 & 255, 1, 0, 24, 0, 0, 0, 0, 0, 255 & i, i >> 8 & 255, i >> 16 & 255, i >> 24 & 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
				l = (4 - 3 * e % 4) % 4,
				c = t.data,
				h = "",
				u = e << 2,
				f = n,
				p = String.fromCharCode;
			do {
				for(var d = u * (f - 1), m = "", g = 0; g < e; g++) {
					var v = g << 2;
					m += p(c[d + v + 2]) + p(c[d + v + 1]) + p(c[d + v])
				}
				for(var _ = 0; _ < l; _++) m += String.fromCharCode(0);
				h += m
			} while (--f);
			return a(o.concat(s)) + a(h)
		},
		u = function(i, a, c, u) {
			if(l.canvas && l.dataURL) {
				if("string" == typeof i && (i = document.getElementById(i)), void 0 == u && (u = "png"), u = r(u), !/bmp/.test(u)) {
					var f = e(i, u, a, c);
					return f
				}
				var p = o(t(i, a, c));
				n(s(f = h(p), "image/octet-stream"))
			}
		},
		f = function(i, a, u, f) {
			if(l.canvas && l.dataURL)
				if("string" == typeof i && (i = document.getElementById(i)), void 0 == f && (f = "png"), f = r(f), /bmp/.test(f)) {
					var p = o(t(i, a, u));
					n(s(d = h(p), "image/octet-stream"))
				} else {
					var d = e(i, f, a, u),
						m = "bim_" + (new Date).getTime() + ".png";
					c(d, m)
				}
		},
		p = function(n, a, c, u) {
			if(l.canvas && l.dataURL) {
				if("string" == typeof n && (n = document.getElementById(n)), void 0 == u && (u = "png"), u = r(u), /bmp/.test(u)) {
					var f = o(t(n, a, c));
					return i(s(p = h(f), "image/bmp"))
				}
				var p = e(n, u, a, c);
				return i(p)
			}
		};
	return {
		getImage: u,
		getPNG: function(t, e, n) {
			return u(t, e, n, "png")
		},
		getJPEG: function(t, e, n) {
			return u(t, e, n, "jpeg")
		},
		getGIF: function(t, e, n) {
			return u(t, e, n, "gif")
		},
		getBMP: function(t, e, n) {
			return u(t, e, n, "bmp")
		},
		saveAsImage: f,
		saveAsPNG: function(t, e, n) {
			return f(t, e, n, "png")
		},
		saveAsJPEG: function(t, e, n) {
			return f(t, e, n, "jpeg")
		},
		saveAsGIF: function(t, e, n) {
			return f(t, e, n, "gif")
		},
		saveAsBMP: function(t, e, n) {
			return f(t, e, n, "bmp")
		},
		convertToImage: p,
		convertToPNG: function(t, e, n) {
			return p(t, e, n, "png")
		},
		convertToJPEG: function(t, e, n) {
			return p(t, e, n, "jpeg")
		},
		convertToGIF: function(t, e, n) {
			return p(t, e, n, "gif")
		},
		convertToBMP: function(t, e, n) {
			return p(t, e, n, "bmp")
		}
	}
}();
GLE.Ts = function(t, e, n) {
	function i(t) {
		!1 !== p.enabled && (window.removeEventListener("keydown", i), v = g, g === d.NONE && (t.keyCode !== p.keys[d.ROTATE] || p.noRotate ? t.keyCode !== p.keys[d.ZOOM] || p.noZoom ? t.keyCode !== p.keys[d.PAN] || p.noPan || (g = d.PAN) : g = d.ZOOM : g = d.ROTATE))
	}

	function r(t) {
		var e = 0,
			n = n || t;
		e = n.keyCode || n.which || n.charCode;
		var i = String.fromCharCode(e);
		"A" == i && (G_35.position.x += .02 * G_32), "S" == i && (G_35.position.y += .02 * G_32), "W" == i && (G_35.position.y -= .02 * G_32), "D" == i && (G_35.position.x -= .02 * G_32)
	}

	function a(t) {
		!1 !== p.enabled && (t.preventDefault(), t.stopPropagation(), g === d.NONE && (g = t.button), g !== d.ROTATE || p.noRotate ? g !== d.ZOOM || p.noZoom ? g !== d.PAN || p.noPan || (G.copy(C(t.pageX, t.pageY)), E.copy(G)) : (b.copy(C(t.pageX, t.pageY)), w.copy(b)) : (x.copy(P(t.pageX, t.pageY)), y.copy(x)), document.addEventListener("mousemove", o, !1), document.addEventListener("mouseup", s, !1), p.dispatchEvent(A))
	}

	function o(t) {
		!1 !== p.enabled && (t.preventDefault(), t.stopPropagation(), g !== d.ROTATE || p.noRotate ? g !== d.ZOOM || p.noZoom ? g !== d.PAN || p.noPan || E.copy(C(t.pageX, t.pageY)) : w.copy(C(t.pageX, t.pageY)) : (y.copy(x), x.copy(P(t.pageX, t.pageY))))
	}

	function s(t) {
		!1 !== p.enabled && (t.preventDefault(), t.stopPropagation(), g = d.NONE, document.removeEventListener("mousemove", o), document.removeEventListener("mouseup", s), p.dispatchEvent(L))
	}

	function l(t) {
		if(!1 !== p.enabled) {
			switch(t.preventDefault(), t.stopPropagation(), t.deltaMode) {
				case 2:
					b.y -= .025 * t.deltaY;
					break;
				case 1:
					b.y -= .01 * t.deltaY;
					break;
				default:
					b.y -= 25e-5 * t.deltaY
			}
			p.dispatchEvent(A), p.dispatchEvent(L)
		}
	}

	function c(t) {
		if(!1 !== p.enabled) {
			switch(t.touches.length) {
				case 1:
					g = d.TOUCH_ROTATE, x.copy(P(t.touches[0].pageX, t.touches[0].pageY)), y.copy(x);
					break;
				default:
					g = d.TOUCH_ZOOM_PAN;
					var e = t.touches[0].pageX - t.touches[1].pageX,
						n = t.touches[0].pageY - t.touches[1].pageY;
					S = M = Math.sqrt(e * e + n * n);
					var i = (t.touches[0].pageX + t.touches[1].pageX) / 2,
						r = (t.touches[0].pageY + t.touches[1].pageY) / 2;
					G.copy(C(i, r)), E.copy(G)
			}
			p.dispatchEvent(A)
		}
	}

	function h(t) {
		if(!1 !== p.enabled) switch(t.preventDefault(), t.stopPropagation(), t.touches.length) {
			case 1:
				y.copy(x), x.copy(P(t.touches[0].pageX, t.touches[0].pageY));
				break;
			default:
				var e = t.touches[0].pageX - t.touches[1].pageX,
					n = t.touches[0].pageY - t.touches[1].pageY;
				S = Math.sqrt(e * e + n * n);
				var i = (t.touches[0].pageX + t.touches[1].pageX) / 2,
					r = (t.touches[0].pageY + t.touches[1].pageY) / 2;
				E.copy(C(i, r))
		}
	}

	function u(t) {
		if(!1 !== p.enabled) {
			switch(t.touches.length) {
				case 0:
					g = d.NONE;
					break;
				case 1:
					g = d.TOUCH_ROTATE, x.copy(P(t.touches[0].pageX, t.touches[0].pageY)), y.copy(x)
			}
			p.dispatchEvent(L)
		}
	}

	function f(t) {
		!1 !== p.enabled && t.preventDefault()
	}
	var p = this,
		d = {
			NONE: -1,
			ROTATE: 0,
			ZOOM: 1,
			PAN: 2,
			TOUCH_ROTATE: 3,
			TOUCH_ZOOM_PAN: 4
		};
	this.object = t, this.domElement = void 0 !== e ? e : document, this.enabled = !0, this.screen = {
		left: 0,
		top: 0,
		width: 0,
		height: 0
	}, this.rd = 1, this.zd = .5, this.pd = .3, this.noRotate = !1, this.noZoom = !1, this.noPan = !1, this.sg = !1, this.dynamicDampingFactor = .2, this.minDistance = 0, this.maxDistance = 1 / 0, this.keys = [65, 83, 68], this.target = new GLE.Vector3;
	var m = new GLE.Vector3,
		g = d.NONE,
		v = d.NONE,
		_ = new GLE.Vector3,
		y = new GLE.Vector2,
		x = new GLE.Vector2,
		b = (new GLE.Vector3, new GLE.Vector2),
		w = new GLE.Vector2,
		M = 0,
		S = 0,
		G = new GLE.Vector2,
		E = new GLE.Vector2;
	_myPan = new GLE.Vector3, this.target0 = this.target.clone(), this.position0 = this.object.position.clone(), this.up0 = this.object.up.clone();
	var T = {
			type: "change"
		},
		A = {
			type: "start"
		},
		L = {
			type: "end"
		};
	this.handleResize = function() {
		if(this.domElement === document) this.screen.left = 0, this.screen.top = 0, this.screen.width = window.innerWidth, this.screen.height = window.innerHeight;
		else {
			var t = this.domElement.getBoundingClientRect(),
				e = this.domElement.ownerDocument.documentElement;
			this.screen.left = t.left + window.pageXOffset - e.clientLeft, this.screen.top = t.top + window.pageYOffset - e.clientTop, this.screen.width = t.width, this.screen.height = t.height
		}
	}, this.handleEvent = function(t) {
		"function" == typeof this[t.type] && this[t.type](t)
	};
	var C = function() {
			var t = new GLE.Vector2;
			return function(e, n) {
				return t.set((e - p.screen.left) / p.screen.width, (n - p.screen.top) / p.screen.height), t
			}
		}(),
		P = function() {
			var t = new GLE.Vector2;
			return function(e, n) {
				return t.set((e - .5 * p.screen.width - p.screen.left) / (.5 * p.screen.width), (p.screen.height + 2 * (p.screen.top - n)) / p.screen.width), t
			}
		}();
	this.rotateCamera = function() {
		new GLE.Vector3, new GLE.Quaternion;
		var t = new GLE.Vector3,
			e = new GLE.Vector3,
			n = new GLE.Vector3,
			i = new GLE.Vector3;
		return function() {
			if(i.set(x.x - y.x, x.y - y.y, 0), s = i.length()) {
				if(G_58 = (new Date).getTime(), _.copy(p.object.position).sub(p.target), t.copy(_).normalize(), e.copy(p.object.up).normalize(), n.crossVectors(e, t).normalize(), e.setLength(x.y - y.y), n.setLength(x.x - y.x), G_35.rotation.z += (x.x - y.x) * this.rd, G_26 && (G_35.rotation.x -= (x.y - y.y) * this.rd), G_24 && G_26) {
					var r = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z) * Math.cos(G_35.rotation.x), Math.sin(G_35.rotation.z) * Math.sin(G_35.rotation.x));
					(G_38 = new GLE.Plane(r, -G_36.position.x - 1 * (G_53.min.x + G_41 * (G_53.max.x - G_53.min.x)))).translate(G_35.position);
					var a = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z), 0),
						o = new GLE.Vector3(0, 0, 1),
						s = Math.PI / 2;
					a.applyAxisAngle(o, s), a = new GLE.Vector3(a.x, a.y * Math.cos(G_35.rotation.x), a.y * Math.sin(G_35.rotation.x)), (G_39 = new GLE.Plane(a, -G_36.position.y - 1 * (G_53.min.y + G_42 * (G_53.max.y - G_53.min.y)))).translate(G_35.position);
					var l = new GLE.Vector3(0, Math.sin(-G_35.rotation.x), Math.cos(-G_35.rotation.x));
					new GLE.Vector3(0, -1, 0), Math.PI;
					(G_40 = new GLE.Plane(l, -G_36.position.z - 1 * (G_53.min.z + G_43 * (G_53.max.z - G_53.min.z)))).translate(G_35.position);
					var c = [G_38, G_39, G_40];
					G_4.cs = c
				}
			} else p.sg;
			y.copy(x)
		}
	}(), this.zoomCamera = function() {
		var t;
		if(g === d.TOUCH_ZOOM_PAN)((t = M / S) > 1.001 || t < .999) && (G_58 = (new Date).getTime()), G_35.position.y -= 2e3 * (1 - t) * p.zd;
		else {
			if(((t = 1 + (w.y - b.y) * p.zd * 8) > 1.001 || t < .999) && (G_58 = (new Date).getTime()), G_53) {
				var e = G_53.getSize().length();
				G_35.position.y -= (1 - t) * e * .2
			} else G_35.position.y -= 1e4 * (1 - t);
			b.copy(w)
		}
		if(G_24) {
			var n = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z) * Math.cos(G_35.rotation.x), Math.sin(G_35.rotation.z) * Math.sin(G_35.rotation.x));
			(G_38 = new GLE.Plane(n, -G_36.position.x - 1 * (G_53.min.x + G_41 * (G_53.max.x - G_53.min.x)))).translate(G_35.position);
			var i = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z), 0),
				r = new GLE.Vector3(0, 0, 1),
				a = Math.PI / 2;
			i.applyAxisAngle(r, a), i = new GLE.Vector3(i.x, i.y * Math.cos(G_35.rotation.x), i.y * Math.sin(G_35.rotation.x)), (G_39 = new GLE.Plane(i, -G_36.position.y - 1 * (G_53.min.y + G_42 * (G_53.max.y - G_53.min.y)))).translate(G_35.position);
			var o = new GLE.Vector3(0, Math.sin(-G_35.rotation.x), Math.cos(-G_35.rotation.x));
			new GLE.Vector3(0, -1, 0), Math.PI;
			(G_40 = new GLE.Plane(o, -G_36.position.z - 1 * (G_53.min.z + G_43 * (G_53.max.z - G_53.min.z)))).translate(G_35.position);
			var s = [G_38, G_39, G_40];
			G_4.cs = s
		}
	}, this.panCamera = function() {
		var t = new GLE.Vector2;
		new GLE.Vector3;
		return function() {
			if(t.copy(E).sub(G), t.lengthSq() > 1e-5) {
				if(G_58 = (new Date).getTime(), G_35.position.x += t.x * G_32 * this.pd, G_35.position.z -= t.y * G_32 * this.pd, G_35.uld(!0), G_24) {
					var e = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z) * Math.cos(G_35.rotation.x), Math.sin(G_35.rotation.z) * Math.sin(G_35.rotation.x));
					(G_38 = new GLE.Plane(e, -G_36.position.x - 1 * (G_53.min.x + G_41 * (G_53.max.x - G_53.min.x)))).translate(new GLE.Vector3(G_35.position.x, G_35.position.y, G_35.position.z));
					var n = new GLE.Vector3(Math.cos(G_35.rotation.z), Math.sin(G_35.rotation.z), 0),
						i = new GLE.Vector3(0, 0, 1),
						r = Math.PI / 2;
					n.applyAxisAngle(i, r), n = new GLE.Vector3(n.x, n.y * Math.cos(G_35.rotation.x), n.y * Math.sin(G_35.rotation.x)), (G_39 = new GLE.Plane(n, -G_36.position.y - 1 * (G_53.min.y + G_42 * (G_53.max.y - G_53.min.y)))).translate(G_35.position);
					var a = new GLE.Vector3(0, Math.sin(-G_35.rotation.x), Math.cos(-G_35.rotation.x));
					new GLE.Vector3(0, -1, 0), Math.PI;
					(G_40 = new GLE.Plane(a, -G_36.position.z - 1 * (G_53.min.z + G_43 * (G_53.max.z - G_53.min.z)))).translate(G_35.position);
					var o = [G_38, G_39, G_40];
					G_4.cs = o
				}
				p.sg ? G.copy(E) : G.add(t.subVectors(E, G).multiplyScalar(p.dynamicDampingFactor))
			}
		}
	}(), this.checkDistances = function() {
		p.noZoom && p.noPan || (_.lengthSq() > p.maxDistance * p.maxDistance && (p.object.position.addVectors(p.target, _.setLength(p.maxDistance)), b.copy(w)), _.lengthSq() < p.minDistance * p.minDistance && (p.object.position.addVectors(p.target, _.setLength(p.minDistance)), b.copy(w)))
	}, this.update = function() {
		p.noZoom || p.zoomCamera(), p.noPan || p.panCamera(), p.noRotate || p.rotateCamera()
	}, this.reset = function() {
		g = d.NONE, v = d.NONE, p.target.copy(p.target0), p.object.position.copy(p.position0), p.object.up.copy(p.up0), _.subVectors(p.object.position, p.target), p.object.lookAt(p.target), p.dispatchEvent(T), m.copy(p.object.position)
	}, this.dispose = function() {
		this.domElement.removeEventListener("contextmenu", f, !1), this.domElement.removeEventListener("mousedown", a, !1), this.domElement.removeEventListener("wheel", l, !1), this.domElement.removeEventListener("touchstart", c, !1), this.domElement.removeEventListener("touchend", u, !1), this.domElement.removeEventListener("touchmove", h, !1), document.removeEventListener("mousemove", o, !1), document.removeEventListener("mouseup", s, !1), window.removeEventListener("keydown", i, !1), window.removeEventListener("keyup", r, !1)
	}, this.domElement.addEventListener("contextmenu", f, !1), this.domElement.addEventListener("mousedown", a, !1), this.domElement.addEventListener("wheel", l, !1), this.domElement.addEventListener("touchstart", c, !1), this.domElement.addEventListener("touchend", u, !1), this.domElement.addEventListener("touchmove", h, !1), window.addEventListener("keydown", i, !1), window.addEventListener("keyup", r, !1), this.handleResize(), this.update()
}, GLE.Ts.prototype = Object.create(GLE.EventDispatcher.prototype), GLE.Ts.prototype.constructor = GLE.Ts;
var TN = TN || function() {
	var t = {},
		e = {},
		n = 0;
	return {
		getAll: function() {
			return Object.keys(t).map(function(e) {
				return t[e]
			})
		},
		removeAll: function() {
			t = {}
		},
		add: function(n) {
			t[n.getId()] = n, e[n.getId()] = n
		},
		remove: function(n) {
			delete t[n.getId()], delete e[n.getId()]
		},
		update: function(n, i) {
			var r = Object.keys(t);
			if(0 === r.length) return !1;
			for(n = void 0 !== n ? n : TN.now(); r.length > 0;) {
				e = {};
				for(var a = 0; a < r.length; a++) !1 !== t[r[a]].update(n) || i || delete t[r[a]];
				r = Object.keys(e)
			}
			return !0
		},
		nextId: function() {
			return n++
		}
	}
}();
"undefined" == typeof window && "undefined" != typeof process ? TN.now = function() {
		var t = process.hrtime();
		return 1e3 * t[0] + t[1] / 1e6
	} : "undefined" != typeof window && void 0 !== window.performance && void 0 !== window.performance.now ? TN.now = window.performance.now.bind(window.performance) : void 0 !== Date.now ? TN.now = Date.now : TN.now = function() {
		return(new Date).getTime()
	}, TN.Tn = function(t) {
		this._object = t, this._valuesStart = {}, this._valuesEnd = {}, this._valuesStartRepeat = {}, this._duration = 1e3, this._repeat = 0, this._repeatDelayTime = void 0, this._yoyo = !1, this._isPlaying = !1, this._reversed = !1, this._delayTime = 0, this._startTime = null, this._easingFunction = TN.Easing.Linear.None, this._interpolationFunction = TN.Interpolation.Linear, this._chainedTns = [], this._onStartCallback = null, this._onStartCallbackFired = !1, this._onUpdateCallback = null, this._onCompleteCallback = null, this._onStopCallback = null, this._id = TN.nextId()
	}, TN.Tn.prototype = assign(Object.create(Object.prototype), {
		getId: function() {
			return this._id
		},
		to: function(t, e) {
			return this._valuesEnd = t, void 0 !== e && (this._duration = e), this
		},
		start: function(t) {
			TN.add(this), this._isPlaying = !0, this._onStartCallbackFired = !1, this._startTime = void 0 !== t ? t : TN.now(), this._startTime += this._delayTime;
			for(var e in this._valuesEnd) {
				if(this._valuesEnd[e] instanceof Array) {
					if(0 === this._valuesEnd[e].length) continue;
					this._valuesEnd[e] = [this._object[e]].concat(this._valuesEnd[e])
				}
				void 0 !== this._object[e] && (this._valuesStart[e] = this._object[e], this._valuesStart[e] instanceof Array == !1 && (this._valuesStart[e] *= 1), this._valuesStartRepeat[e] = this._valuesStart[e] || 0)
			}
			return this
		},
		stop: function() {
			return this._isPlaying ? (TN.remove(this), this._isPlaying = !1, null !== this._onStopCallback && this._onStopCallback.call(this._object, this._object), this.stopChainedTns(), this) : this
		},
		end: function() {
			return this.update(this._startTime + this._duration), this
		},
		stopChainedTns: function() {
			for(var t = 0, e = this._chainedTns.length; t < e; t++) this._chainedTns[t].stop()
		},
		delay: function(t) {
			return this._delayTime = t, this
		},
		repeat: function(t) {
			return this._repeat = t, this
		},
		repeatDelay: function(t) {
			return this._repeatDelayTime = t, this
		},
		yoyo: function(t) {
			return this._yoyo = t, this
		},
		easing: function(t) {
			return this._easingFunction = t, this
		},
		interpolation: function(t) {
			return this._interpolationFunction = t, this
		},
		chain: function() {
			return this._chainedTns = arguments, this
		},
		onStart: function(t) {
			return this._onStartCallback = t, this
		},
		onUpdate: function(t) {
			return this._onUpdateCallback = t, this
		},
		onComplete: function(t) {
			return this._onCompleteCallback = t, this
		},
		onStop: function(t) {
			return this._onStopCallback = t, this
		},
		update: function(t) {
			var e, n, i;
			if(t < this._startTime) return !0;
			!1 === this._onStartCallbackFired && (null !== this._onStartCallback && this._onStartCallback.call(this._object, this._object), this._onStartCallbackFired = !0), n = (n = (t - this._startTime) / this._duration) > 1 ? 1 : n, i = this._easingFunction(n);
			for(e in this._valuesEnd)
				if(void 0 !== this._valuesStart[e]) {
					var r = this._valuesStart[e] || 0,
						a = this._valuesEnd[e];
					a instanceof Array ? this._object[e] = this._interpolationFunction(a, i) : ("string" == typeof a && (a = "+" === a.charAt(0) || "-" === a.charAt(0) ? r + parseFloat(a) : parseFloat(a)), "number" == typeof a && (this._object[e] = r + (a - r) * i))
				}
			if(null !== this._onUpdateCallback && this._onUpdateCallback.call(this._object, i), 1 === n) {
				if(this._repeat > 0) {
					isFinite(this._repeat) && this._repeat--;
					for(e in this._valuesStartRepeat) {
						if("string" == typeof this._valuesEnd[e] && (this._valuesStartRepeat[e] = this._valuesStartRepeat[e] + parseFloat(this._valuesEnd[e])), this._yoyo) {
							var o = this._valuesStartRepeat[e];
							this._valuesStartRepeat[e] = this._valuesEnd[e], this._valuesEnd[e] = o
						}
						this._valuesStart[e] = this._valuesStartRepeat[e]
					}
					return this._yoyo && (this._reversed = !this._reversed), void 0 !== this._repeatDelayTime ? this._startTime = t + this._repeatDelayTime : this._startTime = t + this._delayTime, !0
				}
				null !== this._onCompleteCallback && this._onCompleteCallback.call(this._object, this._object);
				for(var s = 0, l = this._chainedTns.length; s < l; s++) this._chainedTns[s].start(this._startTime + this._duration);
				return !1
			}
			return !0
		}
	}), TN.Easing = {
		Linear: {
			None: function(t) {
				return t
			}
		},
		Quadratic: {
			In: function(t) {
				return t * t
			},
			Out: function(t) {
				return t * (2 - t)
			},
			InOut: function(t) {
				return(t *= 2) < 1 ? .5 * t * t : -.5 * (--t * (t - 2) - 1)
			}
		},
		Cubic: {
			In: function(t) {
				return t * t * t
			},
			Out: function(t) {
				return --t * t * t + 1
			},
			InOut: function(t) {
				return(t *= 2) < 1 ? .5 * t * t * t : .5 * ((t -= 2) * t * t + 2)
			}
		},
		Quartic: {
			In: function(t) {
				return t * t * t * t
			},
			Out: function(t) {
				return 1 - --t * t * t * t
			},
			InOut: function(t) {
				return(t *= 2) < 1 ? .5 * t * t * t * t : -.5 * ((t -= 2) * t * t * t - 2)
			}
		},
		Quintic: {
			In: function(t) {
				return t * t * t * t * t
			},
			Out: function(t) {
				return --t * t * t * t * t + 1
			},
			InOut: function(t) {
				return(t *= 2) < 1 ? .5 * t * t * t * t * t : .5 * ((t -= 2) * t * t * t * t + 2)
			}
		},
		Sinusoidal: {
			In: function(t) {
				return 1 - Math.cos(t * Math.PI / 2)
			},
			Out: function(t) {
				return Math.sin(t * Math.PI / 2)
			},
			InOut: function(t) {
				return .5 * (1 - Math.cos(Math.PI * t))
			}
		},
		Exponential: {
			In: function(t) {
				return 0 === t ? 0 : Math.pow(1024, t - 1)
			},
			Out: function(t) {
				return 1 === t ? 1 : 1 - Math.pow(2, -10 * t)
			},
			InOut: function(t) {
				return 0 === t ? 0 : 1 === t ? 1 : (t *= 2) < 1 ? .5 * Math.pow(1024, t - 1) : .5 * (2 - Math.pow(2, -10 * (t - 1)))
			}
		},
		Circular: {
			In: function(t) {
				return 1 - Math.sqrt(1 - t * t)
			},
			Out: function(t) {
				return Math.sqrt(1 - --t * t)
			},
			InOut: function(t) {
				return(t *= 2) < 1 ? -.5 * (Math.sqrt(1 - t * t) - 1) : .5 * (Math.sqrt(1 - (t -= 2) * t) + 1)
			}
		},
		Elastic: {
			In: function(t) {
				return 0 === t ? 0 : 1 === t ? 1 : -Math.pow(2, 10 * (t - 1)) * Math.sin(5 * (t - 1.1) * Math.PI)
			},
			Out: function(t) {
				return 0 === t ? 0 : 1 === t ? 1 : Math.pow(2, -10 * t) * Math.sin(5 * (t - .1) * Math.PI) + 1
			},
			InOut: function(t) {
				return 0 === t ? 0 : 1 === t ? 1 : (t *= 2, t < 1 ? -.5 * Math.pow(2, 10 * (t - 1)) * Math.sin(5 * (t - 1.1) * Math.PI) : .5 * Math.pow(2, -10 * (t - 1)) * Math.sin(5 * (t - 1.1) * Math.PI) + 1)
			}
		},
		Back: {
			In: function(t) {
				var e = 1.70158;
				return t * t * ((e + 1) * t - e)
			},
			Out: function(t) {
				var e = 1.70158;
				return --t * t * ((e + 1) * t + e) + 1
			},
			InOut: function(t) {
				var e = 2.5949095;
				return(t *= 2) < 1 ? t * t * ((e + 1) * t - e) * .5 : .5 * ((t -= 2) * t * ((e + 1) * t + e) + 2)
			}
		},
		Bounce: {
			In: function(t) {
				return 1 - TN.Easing.Bounce.Out(1 - t)
			},
			Out: function(t) {
				return t < 1 / 2.75 ? 7.5625 * t * t : t < 2 / 2.75 ? 7.5625 * (t -= 1.5 / 2.75) * t + .75 : t < 2.5 / 2.75 ? 7.5625 * (t -= 2.25 / 2.75) * t + .9375 : 7.5625 * (t -= 2.625 / 2.75) * t + .984375
			},
			InOut: function(t) {
				return t < .5 ? .5 * TN.Easing.Bounce.In(2 * t) : .5 * TN.Easing.Bounce.Out(2 * t - 1) + .5
			}
		}
	}, TN.Interpolation = {
		Linear: function(t, e) {
			var n = t.length - 1,
				i = n * e,
				r = Math.floor(i),
				a = TN.Interpolation.Utils.Linear;
			return e < 0 ? a(t[0], t[1], i) : e > 1 ? a(t[n], t[n - 1], n - i) : a(t[r], t[r + 1 > n ? n : r + 1], i - r)
		},
		Bezier: function(t, e) {
			for(var n = 0, i = t.length - 1, r = Math.pow, a = TN.Interpolation.Utils.Bernstein, o = 0; o <= i; o++) n += r(1 - e, i - o) * r(e, o) * t[o] * a(i, o);
			return n
		},
		CatmullRom: function(t, e) {
			var n = t.length - 1,
				i = n * e,
				r = Math.floor(i),
				a = TN.Interpolation.Utils.CatmullRom;
			return t[0] === t[n] ? (e < 0 && (r = Math.floor(i = n * (1 + e))), a(t[(r - 1 + n) % n], t[r], t[(r + 1) % n], t[(r + 2) % n], i - r)) : e < 0 ? t[0] - (a(t[0], t[0], t[1], t[1], -i) - t[0]) : e > 1 ? t[n] - (a(t[n], t[n], t[n - 1], t[n - 1], i - n) - t[n]) : a(t[r ? r - 1 : 0], t[r], t[n < r + 1 ? n : r + 1], t[n < r + 2 ? n : r + 2], i - r)
		},
		Utils: {
			Linear: function(t, e, n) {
				return(e - t) * n + t
			},
			Bernstein: function(t, e) {
				var n = TN.Interpolation.Utils.Factorial;
				return n(t) / n(e) / n(t - e)
			},
			Factorial: function() {
				var t = [1];
				return function(e) {
					var n = 1;
					if(t[e]) return t[e];
					for(var i = e; i > 1; i--) n *= i;
					return t[e] = n, n
				}
			}(),
			CatmullRom: function(t, e, n, i, r) {
				var a = .5 * (n - t),
					o = .5 * (i - e),
					s = r * r;
				return(2 * e - 2 * n + a + o) * (r * s) + (-3 * e + 3 * n - 2 * a - o) * s + a * r + e
			}
		}
	},
	function(t) {
		"function" == typeof define && define.amd ? define([], function() {
			return TN
		}) : "undefined" != typeof module && "object" == typeof exports ? module.exports = TN : void 0 !== t && (t.TN = TN)
	}(this),
	function(t) {
		if("object" == typeof exports && "undefined" != typeof module) module.exports = t();
		else if("function" == typeof define && define.amd) define([], t);
		else {
			("undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof self ? self : this).JSZip = t()
		}
	}(function() {
		return function t(e, n, i) {
			function r(o, s) {
				if(!n[o]) {
					if(!e[o]) {
						var l = "function" == typeof require && require;
						if(!s && l) return l(o, !0);
						if(a) return a(o, !0);
						var c = new Error("Cannot find module '" + o + "'");
						throw c.code = "MODULE_NOT_FOUND", c
					}
					var h = n[o] = {
						exports: {}
					};
					e[o][0].call(h.exports, function(t) {
						var n = e[o][1][t];
						return r(n || t)
					}, h, h.exports, t, e, n, i)
				}
				return n[o].exports
			}
			for(var a = "function" == typeof require && require, o = 0; o < i.length; o++) r(i[o]);
			return r
		}({
			1: [function(t, e, n) {
				"use strict";
				var i = t("./utils"),
					r = t("./support"),
					a = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
				n.encode = function(t) {
					for(var e, n, r, o, s, l, c, h = [], u = 0, f = t.length, p = f, d = "string" !== i.getTypeOf(t); u < t.length;) p = f - u, d ? (e = t[u++], n = u < f ? t[u++] : 0, r = u < f ? t[u++] : 0) : (e = t.charCodeAt(u++), n = u < f ? t.charCodeAt(u++) : 0, r = u < f ? t.charCodeAt(u++) : 0), o = e >> 2, s = (3 & e) << 4 | n >> 4, l = p > 1 ? (15 & n) << 2 | r >> 6 : 64, c = p > 2 ? 63 & r : 64, h.push(a.charAt(o) + a.charAt(s) + a.charAt(l) + a.charAt(c));
					return h.join("")
				}, n.decode = function(t) {
					var e, n, i, o, s, l, c, h = 0,
						u = 0,
						f = "data:";
					if(t.substr(0, f.length) === f) throw new Error("Invalid base64 input, it looks like a data url.");
					var p = 3 * (t = t.replace(/[^A-Za-z0-9\+\/\=]/g, "")).length / 4;
					if(t.charAt(t.length - 1) === a.charAt(64) && p--, t.charAt(t.length - 2) === a.charAt(64) && p--, p % 1 != 0) throw new Error("Invalid base64 input, bad content length.");
					var d;
					for(d = r.uint8array ? new Uint8Array(0 | p) : new Array(0 | p); h < t.length;) o = a.indexOf(t.charAt(h++)), s = a.indexOf(t.charAt(h++)), l = a.indexOf(t.charAt(h++)), c = a.indexOf(t.charAt(h++)), e = o << 2 | s >> 4, n = (15 & s) << 4 | l >> 2, i = (3 & l) << 6 | c, d[u++] = e, 64 !== l && (d[u++] = n), 64 !== c && (d[u++] = i);
					return d
				}
			}, {
				"./support": 30,
				"./utils": 32
			}],
			2: [function(t, e, n) {
				"use strict";

				function i(t, e, n, i, r) {
					this.compressedSize = t, this.uncompressedSize = e, this.crc32 = n, this.compression = i, this.compressedContent = r
				}
				var r = t("./external"),
					a = t("./stream/DataWorker"),
					o = t("./stream/DataLengthProbe"),
					s = t("./stream/Crc32Probe"),
					o = t("./stream/DataLengthProbe");
				i.prototype = {
					getContentWorker: function() {
						var t = new a(r.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new o("data_length")),
							e = this;
						return t.on("end", function() {
							if(this.streamInfo.data_length !== e.uncompressedSize) throw new Error("Bug : uncompressed data size mismatch")
						}), t
					},
					getCompressedWorker: function() {
						return new a(r.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize", this.compressedSize).withStreamInfo("uncompressedSize", this.uncompressedSize).withStreamInfo("crc32", this.crc32).withStreamInfo("compression", this.compression)
					}
				}, i.createWorkerFrom = function(t, e, n) {
					return t.pipe(new s).pipe(new o("uncompressedSize")).pipe(e.compressWorker(n)).pipe(new o("compressedSize")).withStreamInfo("compression", e)
				}, e.exports = i
			}, {
				"./external": 6,
				"./stream/Crc32Probe": 25,
				"./stream/DataLengthProbe": 26,
				"./stream/DataWorker": 27
			}],
			3: [function(t, e, n) {
				"use strict";
				var i = t("./stream/GenericWorker");
				n.STORE = {
					magic: "\0\0",
					compressWorker: function(t) {
						return new i("STORE compression")
					},
					uncompressWorker: function() {
						return new i("STORE decompression")
					}
				}, n.DEFLATE = t("./flate")
			}, {
				"./flate": 7,
				"./stream/GenericWorker": 28
			}],
			4: [function(t, e, n) {
				"use strict";

				function i(t, e, n, i) {
					var r = o,
						a = i + n;
					t ^= -1;
					for(var s = i; s < a; s++) t = t >>> 8 ^ r[255 & (t ^ e[s])];
					return -1 ^ t
				}

				function r(t, e, n, i) {
					var r = o,
						a = i + n;
					t ^= -1;
					for(var s = i; s < a; s++) t = t >>> 8 ^ r[255 & (t ^ e.charCodeAt(s))];
					return -1 ^ t
				}
				var a = t("./utils"),
					o = function() {
						for(var t, e = [], n = 0; n < 256; n++) {
							t = n;
							for(var i = 0; i < 8; i++) t = 1 & t ? 3988292384 ^ t >>> 1 : t >>> 1;
							e[n] = t
						}
						return e
					}();
				e.exports = function(t, e) {
					return void 0 !== t && t.length ? "string" !== a.getTypeOf(t) ? i(0 | e, t, t.length, 0) : r(0 | e, t, t.length, 0) : 0
				}
			}, {
				"./utils": 32
			}],
			5: [function(t, e, n) {
				"use strict";
				n.base64 = !1, n.binary = !1, n.dir = !1, n.createFolders = !0, n.date = null, n.compression = null, n.compressionOptions = null, n.comment = null, n.unixPermissions = null, n.dosPermissions = null
			}, {}],
			6: [function(t, e, n) {
				"use strict";
				var i = null;
				i = "undefined" != typeof Promise ? Promise : t("lie"), e.exports = {
					Promise: i
				}
			}, {
				lie: 58
			}],
			7: [function(t, e, n) {
				"use strict";

				function i(t, e) {
					s.call(this, "FlateWorker/" + t), this._pako = null, this._pakoAction = t, this._pakoOptions = e, this.meta = {}
				}
				var r = "undefined" != typeof Uint8Array && "undefined" != typeof Uint16Array && "undefined" != typeof Uint32Array,
					a = t("pako"),
					o = t("./utils"),
					s = t("./stream/GenericWorker"),
					l = r ? "uint8array" : "array";
				n.magic = "\b\0", o.inherits(i, s), i.prototype.processChunk = function(t) {
					this.meta = t.meta, null === this._pako && this._createPako(), this._pako.push(o.transformTo(l, t.data), !1)
				}, i.prototype.flush = function() {
					s.prototype.flush.call(this), null === this._pako && this._createPako(), this._pako.push([], !0)
				}, i.prototype.cleanUp = function() {
					s.prototype.cleanUp.call(this), this._pako = null
				}, i.prototype._createPako = function() {
					this._pako = new a[this._pakoAction]({
						raw: !0,
						level: this._pakoOptions.level || -1
					});
					var t = this;
					this._pako.onData = function(e) {
						t.push({
							data: e,
							meta: t.meta
						})
					}
				}, n.compressWorker = function(t) {
					return new i("Deflate", t)
				}, n.uncompressWorker = function() {
					return new i("Inflate", {})
				}
			}, {
				"./stream/GenericWorker": 28,
				"./utils": 32,
				pako: 59
			}],
			8: [function(t, e, n) {
				"use strict";

				function i(t, e, n, i) {
					a.call(this, "ZipFileWorker"), this.bytesWritten = 0, this.zipComment = e, this.zipPlatform = n, this.encodeFileName = i, this.streamFiles = t, this.accumulate = !1, this.contentBuffer = [], this.dirRecords = [], this.currentSourceOffset = 0, this.entriesCount = 0, this.currentFile = null, this._sources = []
				}
				var r = t("../utils"),
					a = t("../stream/GenericWorker"),
					o = t("../utf8"),
					s = t("../crc32"),
					l = t("../signature"),
					c = function(t, e) {
						var n, i = "";
						for(n = 0; n < e; n++) i += String.fromCharCode(255 & t), t >>>= 8;
						return i
					},
					h = function(t, e) {
						var n = t;
						return t || (n = e ? 16893 : 33204), (65535 & n) << 16
					},
					u = function(t, e) {
						return 63 & (t || 0)
					},
					f = function(t, e, n, i, a, f) {
						var p, d, m = t.file,
							g = t.compression,
							v = f !== o.utf8encode,
							_ = r.transformTo("string", f(m.name)),
							y = r.transformTo("string", o.utf8encode(m.name)),
							x = m.comment,
							b = r.transformTo("string", f(x)),
							w = r.transformTo("string", o.utf8encode(x)),
							M = y.length !== m.name.length,
							S = w.length !== x.length,
							G = "",
							E = "",
							T = "",
							A = m.dir,
							L = m.date,
							C = {
								crc32: 0,
								compressedSize: 0,
								uncompressedSize: 0
							};
						e && !n || (C.crc32 = t.crc32, C.compressedSize = t.compressedSize, C.uncompressedSize = t.uncompressedSize);
						var P = 0;
						e && (P |= 8), v || !M && !S || (P |= 2048);
						var I = 0,
							R = 0;
						A && (I |= 16), "UNIX" === a ? (R = 798, I |= h(m.unixPermissions, A)) : (R = 20, I |= u(m.dosPermissions)), p = L.getUTCHours(), p <<= 6, p |= L.getUTCMinutes(), p <<= 5, p |= L.getUTCSeconds() / 2, d = L.getUTCFullYear() - 1980, d <<= 4, d |= L.getUTCMonth() + 1, d <<= 5, d |= L.getUTCDate(), M && (E = c(1, 1) + c(s(_), 4) + y, G += "up" + c(E.length, 2) + E), S && (T = c(1, 1) + c(s(b), 4) + w, G += "uc" + c(T.length, 2) + T);
						var O = "";
						return O += "\n\0", O += c(P, 2), O += g.magic, O += c(p, 2), O += c(d, 2), O += c(C.crc32, 4), O += c(C.compressedSize, 4), O += c(C.uncompressedSize, 4), O += c(_.length, 2), O += c(G.length, 2), {
							fileRecord: l.LOCAL_FILE_HEADER + O + _ + G,
							dirRecord: l.CENTRAL_FILE_HEADER + c(R, 2) + O + c(b.length, 2) + "\0\0\0\0" + c(I, 4) + c(i, 4) + _ + G + b
						}
					},
					p = function(t, e, n, i, a) {
						var o = r.transformTo("string", a(i));
						return l.CENTRAL_DIRECTORY_END + "\0\0\0\0" + c(t, 2) + c(t, 2) + c(e, 4) + c(n, 4) + c(o.length, 2) + o
					},
					d = function(t) {
						return l.DATA_DESCRIPTOR + c(t.crc32, 4) + c(t.compressedSize, 4) + c(t.uncompressedSize, 4)
					};
				r.inherits(i, a), i.prototype.push = function(t) {
					var e = t.meta.percent || 0,
						n = this.entriesCount,
						i = this._sources.length;
					this.accumulate ? this.contentBuffer.push(t) : (this.bytesWritten += t.data.length, a.prototype.push.call(this, {
						data: t.data,
						meta: {
							currentFile: this.currentFile,
							percent: n ? (e + 100 * (n - i - 1)) / n : 100
						}
					}))
				}, i.prototype.openedSource = function(t) {
					this.currentSourceOffset = this.bytesWritten, this.currentFile = t.file.name;
					var e = this.streamFiles && !t.file.dir;
					if(e) {
						var n = f(t, e, !1, this.currentSourceOffset, this.zipPlatform, this.encodeFileName);
						this.push({
							data: n.fileRecord,
							meta: {
								percent: 0
							}
						})
					} else this.accumulate = !0
				}, i.prototype.closedSource = function(t) {
					this.accumulate = !1;
					var e = this.streamFiles && !t.file.dir,
						n = f(t, e, !0, this.currentSourceOffset, this.zipPlatform, this.encodeFileName);
					if(this.dirRecords.push(n.dirRecord), e) this.push({
						data: d(t),
						meta: {
							percent: 100
						}
					});
					else
						for(this.push({
								data: n.fileRecord,
								meta: {
									percent: 0
								}
							}); this.contentBuffer.length;) this.push(this.contentBuffer.shift());
					this.currentFile = null
				}, i.prototype.flush = function() {
					for(var t = this.bytesWritten, e = 0; e < this.dirRecords.length; e++) this.push({
						data: this.dirRecords[e],
						meta: {
							percent: 100
						}
					});
					var n = this.bytesWritten - t,
						i = p(this.dirRecords.length, n, t, this.zipComment, this.encodeFileName);
					this.push({
						data: i,
						meta: {
							percent: 100
						}
					})
				}, i.prototype.prepareNextSource = function() {
					this.previous = this._sources.shift(), this.openedSource(this.previous.streamInfo), this.isPaused ? this.previous.pause() : this.previous.resume()
				}, i.prototype.registerPrevious = function(t) {
					this._sources.push(t);
					var e = this;
					return t.on("data", function(t) {
						e.processChunk(t)
					}), t.on("end", function() {
						e.closedSource(e.previous.streamInfo), e._sources.length ? e.prepareNextSource() : e.end()
					}), t.on("error", function(t) {
						e.error(t)
					}), this
				}, i.prototype.resume = function() {
					return !!a.prototype.resume.call(this) && (!this.previous && this._sources.length ? (this.prepareNextSource(), !0) : this.previous || this._sources.length || this.generatedError ? void 0 : (this.end(), !0))
				}, i.prototype.error = function(t) {
					var e = this._sources;
					if(!a.prototype.error.call(this, t)) return !1;
					for(var n = 0; n < e.length; n++) try {
						e[n].error(t)
					} catch(t) {}
					return !0
				}, i.prototype.lock = function() {
					a.prototype.lock.call(this);
					for(var t = this._sources, e = 0; e < t.length; e++) t[e].lock()
				}, e.exports = i
			}, {
				"../crc32": 4,
				"../signature": 23,
				"../stream/GenericWorker": 28,
				"../utf8": 31,
				"../utils": 32
			}],
			9: [function(t, e, n) {
				"use strict";
				var i = t("../compressions"),
					r = t("./ZipFileWorker"),
					a = function(t, e) {
						var n = t || e,
							r = i[n];
						if(!r) throw new Error(n + " is not a valid compression method !");
						return r
					};
				n.generateWorker = function(t, e, n) {
					var i = new r(e.streamFiles, n, e.platform, e.encodeFileName),
						o = 0;
					try {
						t.forEach(function(t, n) {
							o++;
							var r = a(n.options.compression, e.compression),
								s = n.options.compressionOptions || e.compressionOptions || {},
								l = n.dir,
								c = n.date;
							n._compressWorker(r, s).withStreamInfo("file", {
								name: t,
								dir: l,
								date: c,
								comment: n.comment || "",
								unixPermissions: n.unixPermissions,
								dosPermissions: n.dosPermissions
							}).pipe(i)
						}), i.entriesCount = o
					} catch(t) {
						i.error(t)
					}
					return i
				}
			}, {
				"../compressions": 3,
				"./ZipFileWorker": 8
			}],
			10: [function(t, e, n) {
				"use strict";

				function i() {
					if(!(this instanceof i)) return new i;
					if(arguments.length) throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");
					this.files = {}, this.comment = null, this.root = "", this.clone = function() {
						var t = new i;
						for(var e in this) "function" != typeof this[e] && (t[e] = this[e]);
						return t
					}
				}
				i.prototype = t("./object"), i.prototype.loadAsync = t("./load"), i.support = t("./support"), i.defaults = t("./defaults"), i.version = "3.1.5", i.loadAsync = function(t, e) {
					return(new i).loadAsync(t, e)
				}, i.external = t("./external"), e.exports = i
			}, {
				"./defaults": 5,
				"./external": 6,
				"./load": 11,
				"./object": 15,
				"./support": 30
			}],
			11: [function(t, e, n) {
				"use strict";

				function i(t) {
					return new a.Promise(function(e, n) {
						var i = t.decompressed.getContentWorker().pipe(new l);
						i.on("error", function(t) {
							n(t)
						}).on("end", function() {
							i.streamInfo.crc32 !== t.decompressed.crc32 ? n(new Error("Corrupted zip : CRC32 mismatch")) : e()
						}).resume()
					})
				}
				var r = t("./utils"),
					a = t("./external"),
					o = t("./utf8"),
					r = t("./utils"),
					s = t("./zipEntries"),
					l = t("./stream/Crc32Probe"),
					c = t("./nodejsUtils");
				e.exports = function(t, e) {
					var n = this;
					return e = r.extend(e || {}, {
						base64: !1,
						checkCRC32: !1,
						optimizedBinaryString: !1,
						createFolders: !1,
						decodeFileName: o.utf8decode
					}), c.isNode && c.isStream(t) ? a.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")) : r.prepareContent("the loaded zip file", t, !0, e.optimizedBinaryString, e.base64).then(function(t) {
						var n = new s(e);
						return n.load(t), n
					}).then(function(t) {
						var n = [a.Promise.resolve(t)],
							r = t.files;
						if(e.checkCRC32)
							for(var o = 0; o < r.length; o++) n.push(i(r[o]));
						return a.Promise.all(n)
					}).then(function(t) {
						for(var i = t.shift(), r = i.files, a = 0; a < r.length; a++) {
							var o = r[a];
							n.file(o.fileNameStr, o.decompressed, {
								binary: !0,
								optimizedBinaryString: !0,
								date: o.date,
								dir: o.dir,
								comment: o.fileCommentStr.length ? o.fileCommentStr : null,
								unixPermissions: o.unixPermissions,
								dosPermissions: o.dosPermissions,
								createFolders: e.createFolders
							})
						}
						return i.zipComment.length && (n.comment = i.zipComment), n
					})
				}
			}, {
				"./external": 6,
				"./nodejsUtils": 14,
				"./stream/Crc32Probe": 25,
				"./utf8": 31,
				"./utils": 32,
				"./zipEntries": 33
			}],
			12: [function(t, e, n) {
				"use strict";

				function i(t, e) {
					a.call(this, "Nodejs stream input adapter for " + t), this._upstreamEnded = !1, this._bindStream(e)
				}
				var r = t("../utils"),
					a = t("../stream/GenericWorker");
				r.inherits(i, a), i.prototype._bindStream = function(t) {
					var e = this;
					this._stream = t, t.pause(), t.on("data", function(t) {
						e.push({
							data: t,
							meta: {
								percent: 0
							}
						})
					}).on("error", function(t) {
						e.isPaused ? this.generatedError = t : e.error(t)
					}).on("end", function() {
						e.isPaused ? e._upstreamEnded = !0 : e.end()
					})
				}, i.prototype.pause = function() {
					return !!a.prototype.pause.call(this) && (this._stream.pause(), !0)
				}, i.prototype.resume = function() {
					return !!a.prototype.resume.call(this) && (this._upstreamEnded ? this.end() : this._stream.resume(), !0)
				}, e.exports = i
			}, {
				"../stream/GenericWorker": 28,
				"../utils": 32
			}],
			13: [function(t, e, n) {
				"use strict";

				function i(t, e, n) {
					r.call(this, e), this._helper = t;
					var i = this;
					t.on("data", function(t, e) {
						i.push(t) || i._helper.pause(), n && n(e)
					}).on("error", function(t) {
						i.emit("error", t)
					}).on("end", function() {
						i.push(null)
					})
				}
				var r = t("readable-stream").Readable;
				t("../utils").inherits(i, r), i.prototype._read = function() {
					this._helper.resume()
				}, e.exports = i
			}, {
				"../utils": 32,
				"readable-stream": 16
			}],
			14: [function(t, e, n) {
				"use strict";
				e.exports = {
					isNode: "undefined" != typeof Buffer,
					newBufferFrom: function(t, e) {
						return new Buffer(t, e)
					},
					allocBuffer: function(t) {
						return Buffer.alloc ? Buffer.alloc(t) : new Buffer(t)
					},
					isBuffer: function(t) {
						return Buffer.isBuffer(t)
					},
					isStream: function(t) {
						return t && "function" == typeof t.on && "function" == typeof t.pause && "function" == typeof t.resume
					}
				}
			}, {}],
			15: [function(t, e, n) {
				"use strict";

				function i(t) {
					return "[object RegExp]" === Object.prototype.toString.call(t)
				}
				var r = t("./utf8"),
					a = t("./utils"),
					o = t("./stream/GenericWorker"),
					s = t("./stream/StreamHelper"),
					l = t("./defaults"),
					c = t("./compressedObject"),
					h = t("./zipObject"),
					u = t("./generate"),
					f = t("./nodejsUtils"),
					p = t("./nodejs/NodejsStreamInputAdapter"),
					d = function(t, e, n) {
						var i, r = a.getTypeOf(e),
							s = a.extend(n || {}, l);
						s.date = s.date || new Date, null !== s.compression && (s.compression = s.compression.toUpperCase()), "string" == typeof s.unixPermissions && (s.unixPermissions = parseInt(s.unixPermissions, 8)), s.unixPermissions && 16384 & s.unixPermissions && (s.dir = !0), s.dosPermissions && 16 & s.dosPermissions && (s.dir = !0), s.dir && (t = g(t)), s.createFolders && (i = m(t)) && v.call(this, i, !0);
						var u = "string" === r && !1 === s.binary && !1 === s.base64;
						n && void 0 !== n.binary || (s.binary = !u), (e instanceof c && 0 === e.uncompressedSize || s.dir || !e || 0 === e.length) && (s.base64 = !1, s.binary = !0, e = "", s.compression = "STORE", r = "string");
						var d = null;
						d = e instanceof c || e instanceof o ? e : f.isNode && f.isStream(e) ? new p(t, e) : a.prepareContent(t, e, s.binary, s.optimizedBinaryString, s.base64);
						var _ = new h(t, d, s);
						this.files[t] = _
					},
					m = function(t) {
						"/" === t.slice(-1) && (t = t.substring(0, t.length - 1));
						var e = t.lastIndexOf("/");
						return e > 0 ? t.substring(0, e) : ""
					},
					g = function(t) {
						return "/" !== t.slice(-1) && (t += "/"), t
					},
					v = function(t, e) {
						return e = void 0 !== e ? e : l.createFolders, t = g(t), this.files[t] || d.call(this, t, null, {
							dir: !0,
							createFolders: e
						}), this.files[t]
					},
					_ = {
						load: function() {
							throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")
						},
						forEach: function(t) {
							var e, n, i;
							for(e in this.files) this.files.hasOwnProperty(e) && (i = this.files[e], (n = e.slice(this.root.length, e.length)) && e.slice(0, this.root.length) === this.root && t(n, i))
						},
						filter: function(t) {
							var e = [];
							return this.forEach(function(n, i) {
								t(n, i) && e.push(i)
							}), e
						},
						file: function(t, e, n) {
							if(1 === arguments.length) {
								if(i(t)) {
									var r = t;
									return this.filter(function(t, e) {
										return !e.dir && r.test(t)
									})
								}
								var a = this.files[this.root + t];
								return a && !a.dir ? a : null
							}
							return t = this.root + t, d.call(this, t, e, n), this
						},
						folder: function(t) {
							if(!t) return this;
							if(i(t)) return this.filter(function(e, n) {
								return n.dir && t.test(e)
							});
							var e = this.root + t,
								n = v.call(this, e),
								r = this.clone();
							return r.root = n.name, r
						},
						remove: function(t) {
							t = this.root + t;
							var e = this.files[t];
							if(e || ("/" !== t.slice(-1) && (t += "/"), e = this.files[t]), e && !e.dir) delete this.files[t];
							else
								for(var n = this.filter(function(e, n) {
										return n.name.slice(0, t.length) === t
									}), i = 0; i < n.length; i++) delete this.files[n[i].name];
							return this
						},
						generate: function(t) {
							throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")
						},
						generateInternalStream: function(t) {
							var e, n = {};
							try {
								if(n = a.extend(t || {}, {
										streamFiles: !1,
										compression: "STORE",
										compressionOptions: null,
										type: "",
										platform: "DOS",
										comment: null,
										mimeType: "application/zip",
										encodeFileName: r.utf8encode
									}), n.type = n.type.toLowerCase(), n.compression = n.compression.toUpperCase(), "binarystring" === n.type && (n.type = "string"), !n.type) throw new Error("No output type specified.");
								a.checkSupport(n.type), "darwin" !== n.platform && "freebsd" !== n.platform && "linux" !== n.platform && "sunos" !== n.platform || (n.platform = "UNIX"), "win32" === n.platform && (n.platform = "DOS");
								var i = n.comment || this.comment || "";
								e = u.generateWorker(this, n, i)
							} catch(t) {
								(e = new o("error")).error(t)
							}
							return new s(e, n.type || "string", n.mimeType)
						},
						generateAsync: function(t, e) {
							return this.generateInternalStream(t).accumulate(e)
						},
						generateNodeStream: function(t, e) {
							return(t = t || {}).type || (t.type = "nodebuffer"), this.generateInternalStream(t).toNodejsStream(e)
						}
					};
				e.exports = _
			}, {
				"./compressedObject": 2,
				"./defaults": 5,
				"./generate": 9,
				"./nodejs/NodejsStreamInputAdapter": 12,
				"./nodejsUtils": 14,
				"./stream/GenericWorker": 28,
				"./stream/StreamHelper": 29,
				"./utf8": 31,
				"./utils": 32,
				"./zipObject": 35
			}],
			16: [function(t, e, n) {
				e.exports = t("stream")
			}, {
				stream: void 0
			}],
			17: [function(t, e, n) {
				"use strict";

				function i(t) {
					r.call(this, t);
					for(var e = 0; e < this.data.length; e++) t[e] = 255 & t[e]
				}
				var r = t("./DataReader");
				t("../utils").inherits(i, r), i.prototype.byteAt = function(t) {
					return this.data[this.zero + t]
				}, i.prototype.lastIndexOfSignature = function(t) {
					for(var e = t.charCodeAt(0), n = t.charCodeAt(1), i = t.charCodeAt(2), r = t.charCodeAt(3), a = this.length - 4; a >= 0; --a)
						if(this.data[a] === e && this.data[a + 1] === n && this.data[a + 2] === i && this.data[a + 3] === r) return a - this.zero;
					return -1
				}, i.prototype.readAndCheckSignature = function(t) {
					var e = t.charCodeAt(0),
						n = t.charCodeAt(1),
						i = t.charCodeAt(2),
						r = t.charCodeAt(3),
						a = this.readData(4);
					return e === a[0] && n === a[1] && i === a[2] && r === a[3]
				}, i.prototype.readData = function(t) {
					if(this.checkOffset(t), 0 === t) return [];
					var e = this.data.slice(this.zero + this.index, this.zero + this.index + t);
					return this.index += t, e
				}, e.exports = i
			}, {
				"../utils": 32,
				"./DataReader": 18
			}],
			18: [function(t, e, n) {
				"use strict";

				function i(t) {
					this.data = t, this.length = t.length, this.index = 0, this.zero = 0
				}
				var r = t("../utils");
				i.prototype = {
					checkOffset: function(t) {
						this.checkIndex(this.index + t)
					},
					checkIndex: function(t) {
						if(this.length < this.zero + t || t < 0) throw new Error("End of data reached (data length = " + this.length + ", asked index = " + t + "). Corrupted zip ?")
					},
					setIndex: function(t) {
						this.checkIndex(t), this.index = t
					},
					skip: function(t) {
						this.setIndex(this.index + t)
					},
					byteAt: function(t) {},
					readInt: function(t) {
						var e, n = 0;
						for(this.checkOffset(t), e = this.index + t - 1; e >= this.index; e--) n = (n << 8) + this.byteAt(e);
						return this.index += t, n
					},
					readString: function(t) {
						return r.transformTo("string", this.readData(t))
					},
					readData: function(t) {},
					lastIndexOfSignature: function(t) {},
					readAndCheckSignature: function(t) {},
					readDate: function() {
						var t = this.readInt(4);
						return new Date(Date.UTC(1980 + (t >> 25 & 127), (t >> 21 & 15) - 1, t >> 16 & 31, t >> 11 & 31, t >> 5 & 63, (31 & t) << 1))
					}
				}, e.exports = i
			}, {
				"../utils": 32
			}],
			19: [function(t, e, n) {
				"use strict";

				function i(t) {
					r.call(this, t)
				}
				var r = t("./Uint8ArrayReader");
				t("../utils").inherits(i, r), i.prototype.readData = function(t) {
					this.checkOffset(t);
					var e = this.data.slice(this.zero + this.index, this.zero + this.index + t);
					return this.index += t, e
				}, e.exports = i
			}, {
				"../utils": 32,
				"./Uint8ArrayReader": 21
			}],
			20: [function(t, e, n) {
				"use strict";

				function i(t) {
					r.call(this, t)
				}
				var r = t("./DataReader");
				t("../utils").inherits(i, r), i.prototype.byteAt = function(t) {
					return this.data.charCodeAt(this.zero + t)
				}, i.prototype.lastIndexOfSignature = function(t) {
					return this.data.lastIndexOf(t) - this.zero
				}, i.prototype.readAndCheckSignature = function(t) {
					return t === this.readData(4)
				}, i.prototype.readData = function(t) {
					this.checkOffset(t);
					var e = this.data.slice(this.zero + this.index, this.zero + this.index + t);
					return this.index += t, e
				}, e.exports = i
			}, {
				"../utils": 32,
				"./DataReader": 18
			}],
			21: [function(t, e, n) {
				"use strict";

				function i(t) {
					r.call(this, t)
				}
				var r = t("./ArrayReader");
				t("../utils").inherits(i, r), i.prototype.readData = function(t) {
					if(this.checkOffset(t), 0 === t) return new Uint8Array(0);
					var e = this.data.subarray(this.zero + this.index, this.zero + this.index + t);
					return this.index += t, e
				}, e.exports = i
			}, {
				"../utils": 32,
				"./ArrayReader": 17
			}],
			22: [function(t, e, n) {
				"use strict";
				var i = t("../utils"),
					r = t("../support"),
					a = t("./ArrayReader"),
					o = t("./StringReader"),
					s = t("./NodeBufferReader"),
					l = t("./Uint8ArrayReader");
				e.exports = function(t) {
					var e = i.getTypeOf(t);
					return i.checkSupport(e), "string" !== e || r.uint8array ? "nodebuffer" === e ? new s(t) : r.uint8array ? new l(i.transformTo("uint8array", t)) : new a(i.transformTo("array", t)) : new o(t)
				}
			}, {
				"../support": 30,
				"../utils": 32,
				"./ArrayReader": 17,
				"./NodeBufferReader": 19,
				"./StringReader": 20,
				"./Uint8ArrayReader": 21
			}],
			23: [function(t, e, n) {
				"use strict";
				n.LOCAL_FILE_HEADER = "PK", n.CENTRAL_FILE_HEADER = "PK", n.CENTRAL_DIRECTORY_END = "PK", n.ZIP64_CENTRAL_DIRECTORY_LOCATOR = "PK", n.ZIP64_CENTRAL_DIRECTORY_END = "PK", n.DATA_DESCRIPTOR = "PK\b"
			}, {}],
			24: [function(t, e, n) {
				"use strict";

				function i(t) {
					r.call(this, "ConvertWorker to " + t), this.destType = t
				}
				var r = t("./GenericWorker"),
					a = t("../utils");
				a.inherits(i, r), i.prototype.processChunk = function(t) {
					this.push({
						data: a.transformTo(this.destType, t.data),
						meta: t.meta
					})
				}, e.exports = i
			}, {
				"../utils": 32,
				"./GenericWorker": 28
			}],
			25: [function(t, e, n) {
				"use strict";

				function i() {
					r.call(this, "Crc32Probe"), this.withStreamInfo("crc32", 0)
				}
				var r = t("./GenericWorker"),
					a = t("../crc32");
				t("../utils").inherits(i, r), i.prototype.processChunk = function(t) {
					this.streamInfo.crc32 = a(t.data, this.streamInfo.crc32 || 0), this.push(t)
				}, e.exports = i
			}, {
				"../crc32": 4,
				"../utils": 32,
				"./GenericWorker": 28
			}],
			26: [function(t, e, n) {
				"use strict";

				function i(t) {
					a.call(this, "DataLengthProbe for " + t), this.propName = t, this.withStreamInfo(t, 0)
				}
				var r = t("../utils"),
					a = t("./GenericWorker");
				r.inherits(i, a), i.prototype.processChunk = function(t) {
					if(t) {
						var e = this.streamInfo[this.propName] || 0;
						this.streamInfo[this.propName] = e + t.data.length
					}
					a.prototype.processChunk.call(this, t)
				}, e.exports = i
			}, {
				"../utils": 32,
				"./GenericWorker": 28
			}],
			27: [function(t, e, n) {
				"use strict";

				function i(t) {
					a.call(this, "DataWorker");
					var e = this;
					this.dataIsReady = !1, this.index = 0, this.max = 0, this.data = null, this.type = "", this._tickScheduled = !1, t.then(function(t) {
						e.dataIsReady = !0, e.data = t, e.max = t && t.length || 0, e.type = r.getTypeOf(t), e.isPaused || e._tickAndRepeat()
					}, function(t) {
						e.error(t)
					})
				}
				var r = t("../utils"),
					a = t("./GenericWorker");
				r.inherits(i, a), i.prototype.cleanUp = function() {
					a.prototype.cleanUp.call(this), this.data = null
				}, i.prototype.resume = function() {
					return !!a.prototype.resume.call(this) && (!this._tickScheduled && this.dataIsReady && (this._tickScheduled = !0, r.delay(this._tickAndRepeat, [], this)), !0)
				}, i.prototype._tickAndRepeat = function() {
					this._tickScheduled = !1, this.isPaused || this.isFinished || (this._tick(), this.isFinished || (r.delay(this._tickAndRepeat, [], this), this._tickScheduled = !0))
				}, i.prototype._tick = function() {
					if(this.isPaused || this.isFinished) return !1;
					var t = null,
						e = Math.min(this.max, this.index + 16384);
					if(this.index >= this.max) return this.end();
					switch(this.type) {
						case "string":
							t = this.data.substring(this.index, e);
							break;
						case "uint8array":
							t = this.data.subarray(this.index, e);
							break;
						case "array":
						case "nodebuffer":
							t = this.data.slice(this.index, e)
					}
					return this.index = e, this.push({
						data: t,
						meta: {
							percent: this.max ? this.index / this.max * 100 : 0
						}
					})
				}, e.exports = i
			}, {
				"../utils": 32,
				"./GenericWorker": 28
			}],
			28: [function(t, e, n) {
				"use strict";

				function i(t) {
					this.name = t || "default", this.streamInfo = {}, this.generatedError = null, this.extraStreamInfo = {}, this.isPaused = !0, this.isFinished = !1, this.isLocked = !1, this._listeners = {
						data: [],
						end: [],
						error: []
					}, this.previous = null
				}
				i.prototype = {
					push: function(t) {
						this.emit("data", t)
					},
					end: function() {
						if(this.isFinished) return !1;
						this.flush();
						try {
							this.emit("end"), this.cleanUp(), this.isFinished = !0
						} catch(t) {
							this.emit("error", t)
						}
						return !0
					},
					error: function(t) {
						return !this.isFinished && (this.isPaused ? this.generatedError = t : (this.isFinished = !0, this.emit("error", t), this.previous && this.previous.error(t), this.cleanUp()), !0)
					},
					on: function(t, e) {
						return this._listeners[t].push(e), this
					},
					cleanUp: function() {
						this.streamInfo = this.generatedError = this.extraStreamInfo = null, this._listeners = []
					},
					emit: function(t, e) {
						if(this._listeners[t])
							for(var n = 0; n < this._listeners[t].length; n++) this._listeners[t][n].call(this, e)
					},
					pipe: function(t) {
						return t.registerPrevious(this)
					},
					registerPrevious: function(t) {
						if(this.isLocked) throw new Error("The stream '" + this + "' has already been used.");
						this.streamInfo = t.streamInfo, this.mergeStreamInfo(), this.previous = t;
						var e = this;
						return t.on("data", function(t) {
							e.processChunk(t)
						}), t.on("end", function() {
							e.end()
						}), t.on("error", function(t) {
							e.error(t)
						}), this
					},
					pause: function() {
						return !this.isPaused && !this.isFinished && (this.isPaused = !0, this.previous && this.previous.pause(), !0)
					},
					resume: function() {
						if(!this.isPaused || this.isFinished) return !1;
						this.isPaused = !1;
						var t = !1;
						return this.generatedError && (this.error(this.generatedError), t = !0), this.previous && this.previous.resume(), !t
					},
					flush: function() {},
					processChunk: function(t) {
						this.push(t)
					},
					withStreamInfo: function(t, e) {
						return this.extraStreamInfo[t] = e, this.mergeStreamInfo(), this
					},
					mergeStreamInfo: function() {
						for(var t in this.extraStreamInfo) this.extraStreamInfo.hasOwnProperty(t) && (this.streamInfo[t] = this.extraStreamInfo[t])
					},
					lock: function() {
						if(this.isLocked) throw new Error("The stream '" + this + "' has already been used.");
						this.isLocked = !0, this.previous && this.previous.lock()
					},
					toString: function() {
						var t = "Worker " + this.name;
						return this.previous ? this.previous + " -> " + t : t
					}
				}, e.exports = i
			}, {}],
			29: [function(t, e, n) {
				"use strict";

				function i(t, e, n) {
					switch(t) {
						case "blob":
							return s.newBlob(s.transformTo("arraybuffer", e), n);
						case "base64":
							return h.encode(e);
						default:
							return s.transformTo(t, e)
					}
				}

				function r(t, e) {
					var n, i = 0,
						r = null,
						a = 0;
					for(n = 0; n < e.length; n++) a += e[n].length;
					switch(t) {
						case "string":
							return e.join("");
						case "array":
							return Array.prototype.concat.apply([], e);
						case "uint8array":
							for(r = new Uint8Array(a), n = 0; n < e.length; n++) r.set(e[n], i), i += e[n].length;
							return r;
						case "nodebuffer":
							return Buffer.concat(e);
						default:
							throw new Error("concat : unsupported type '" + t + "'")
					}
				}

				function a(t, e) {
					return new f.Promise(function(n, a) {
						var o = [],
							s = t._internalType,
							l = t._outputType,
							c = t._mimeType;
						t.on("data", function(t, n) {
							o.push(t), e && e(n)
						}).on("error", function(t) {
							o = [], a(t)
						}).on("end", function() {
							try {
								var t = i(l, r(s, o), c);
								n(t)
							} catch(t) {
								a(t)
							}
							o = []
						}).resume()
					})
				}

				function o(t, e, n) {
					var i = e;
					switch(e) {
						case "blob":
						case "arraybuffer":
							i = "uint8array";
							break;
						case "base64":
							i = "string"
					}
					try {
						this._internalType = i, this._outputType = e, this._mimeType = n, s.checkSupport(i), this._worker = t.pipe(new l(i)), t.lock()
					} catch(t) {
						this._worker = new c("error"), this._worker.error(t)
					}
				}
				var s = t("../utils"),
					l = t("./ConvertWorker"),
					c = t("./GenericWorker"),
					h = t("../base64"),
					u = t("../support"),
					f = t("../external"),
					p = null;
				if(u.nodestream) try {
					p = t("../nodejs/NodejsStreamOutputAdapter")
				} catch(t) {}
				o.prototype = {
					accumulate: function(t) {
						return a(this, t)
					},
					on: function(t, e) {
						var n = this;
						return "data" === t ? this._worker.on(t, function(t) {
							e.call(n, t.data, t.meta)
						}) : this._worker.on(t, function() {
							s.delay(e, arguments, n)
						}), this
					},
					resume: function() {
						return s.delay(this._worker.resume, [], this._worker), this
					},
					pause: function() {
						return this._worker.pause(), this
					},
					toNodejsStream: function(t) {
						if(s.checkSupport("nodestream"), "nodebuffer" !== this._outputType) throw new Error(this._outputType + " is not supported by this method");
						return new p(this, {
							objectMode: "nodebuffer" !== this._outputType
						}, t)
					}
				}, e.exports = o
			}, {
				"../base64": 1,
				"../external": 6,
				"../nodejs/NodejsStreamOutputAdapter": 13,
				"../support": 30,
				"../utils": 32,
				"./ConvertWorker": 24,
				"./GenericWorker": 28
			}],
			30: [function(t, e, n) {
				"use strict";
				if(n.base64 = !0, n.array = !0, n.string = !0, n.arraybuffer = "undefined" != typeof ArrayBuffer && "undefined" != typeof Uint8Array, n.nodebuffer = "undefined" != typeof Buffer, n.uint8array = "undefined" != typeof Uint8Array, "undefined" == typeof ArrayBuffer) n.blob = !1;
				else {
					var i = new ArrayBuffer(0);
					try {
						n.blob = 0 === new Blob([i], {
							type: "application/zip"
						}).size
					} catch(t) {
						try {
							var r = new(self.BlobBuilder || self.WebKitBlobBuilder || self.MozBlobBuilder || self.MSBlobBuilder);
							r.append(i), n.blob = 0 === r.getBlob("application/zip").size
						} catch(t) {
							n.blob = !1
						}
					}
				}
				try {
					n.nodestream = !!t("readable-stream").Readable
				} catch(t) {
					n.nodestream = !1
				}
			}, {
				"readable-stream": 16
			}],
			31: [function(t, e, n) {
				"use strict";

				function i() {
					l.call(this, "utf-8 decode"), this.leftOver = null
				}

				function r() {
					l.call(this, "utf-8 encode")
				}
				for(var a = t("./utils"), o = t("./support"), s = t("./nodejsUtils"), l = t("./stream/GenericWorker"), c = new Array(256), h = 0; h < 256; h++) c[h] = h >= 252 ? 6 : h >= 248 ? 5 : h >= 240 ? 4 : h >= 224 ? 3 : h >= 192 ? 2 : 1;
				c[254] = c[254] = 1;
				var u = function(t) {
						var e, n, i, r, a, s = t.length,
							l = 0;
						for(r = 0; r < s; r++) 55296 == (64512 & (n = t.charCodeAt(r))) && r + 1 < s && 56320 == (64512 & (i = t.charCodeAt(r + 1))) && (n = 65536 + (n - 55296 << 10) + (i - 56320), r++), l += n < 128 ? 1 : n < 2048 ? 2 : n < 65536 ? 3 : 4;
						for(e = o.uint8array ? new Uint8Array(l) : new Array(l), a = 0, r = 0; a < l; r++) 55296 == (64512 & (n = t.charCodeAt(r))) && r + 1 < s && 56320 == (64512 & (i = t.charCodeAt(r + 1))) && (n = 65536 + (n - 55296 << 10) + (i - 56320), r++), n < 128 ? e[a++] = n : n < 2048 ? (e[a++] = 192 | n >>> 6, e[a++] = 128 | 63 & n) : n < 65536 ? (e[a++] = 224 | n >>> 12, e[a++] = 128 | n >>> 6 & 63, e[a++] = 128 | 63 & n) : (e[a++] = 240 | n >>> 18, e[a++] = 128 | n >>> 12 & 63, e[a++] = 128 | n >>> 6 & 63, e[a++] = 128 | 63 & n);
						return e
					},
					f = function(t, e) {
						var n;
						for((e = e || t.length) > t.length && (e = t.length), n = e - 1; n >= 0 && 128 == (192 & t[n]);) n--;
						return n < 0 ? e : 0 === n ? e : n + c[t[n]] > e ? n : e
					},
					p = function(t) {
						var e, n, i, r, o = t.length,
							s = new Array(2 * o);
						for(n = 0, e = 0; e < o;)
							if((i = t[e++]) < 128) s[n++] = i;
							else if((r = c[i]) > 4) s[n++] = 65533, e += r - 1;
						else {
							for(i &= 2 === r ? 31 : 3 === r ? 15 : 7; r > 1 && e < o;) i = i << 6 | 63 & t[e++], r--;
							r > 1 ? s[n++] = 65533 : i < 65536 ? s[n++] = i : (i -= 65536, s[n++] = 55296 | i >> 10 & 1023, s[n++] = 56320 | 1023 & i)
						}
						return s.length !== n && (s.subarray ? s = s.subarray(0, n) : s.length = n), a.applyFromCharCode(s)
					};
				n.utf8encode = function(t) {
					return o.nodebuffer ? s.newBufferFrom(t, "utf-8") : u(t)
				}, n.utf8decode = function(t) {
					return o.nodebuffer ? a.transformTo("nodebuffer", t).toString("utf-8") : (t = a.transformTo(o.uint8array ? "uint8array" : "array", t), p(t))
				}, a.inherits(i, l), i.prototype.processChunk = function(t) {
					var e = a.transformTo(o.uint8array ? "uint8array" : "array", t.data);
					if(this.leftOver && this.leftOver.length) {
						if(o.uint8array) {
							var i = e;
							(e = new Uint8Array(i.length + this.leftOver.length)).set(this.leftOver, 0), e.set(i, this.leftOver.length)
						} else e = this.leftOver.concat(e);
						this.leftOver = null
					}
					var r = f(e),
						s = e;
					r !== e.length && (o.uint8array ? (s = e.subarray(0, r), this.leftOver = e.subarray(r, e.length)) : (s = e.slice(0, r), this.leftOver = e.slice(r, e.length))), this.push({
						data: n.utf8decode(s),
						meta: t.meta
					})
				}, i.prototype.flush = function() {
					this.leftOver && this.leftOver.length && (this.push({
						data: n.utf8decode(this.leftOver),
						meta: {}
					}), this.leftOver = null)
				}, n.Utf8DecodeWorker = i, a.inherits(r, l), r.prototype.processChunk = function(t) {
					this.push({
						data: n.utf8encode(t.data),
						meta: t.meta
					})
				}, n.Utf8EncodeWorker = r
			}, {
				"./nodejsUtils": 14,
				"./stream/GenericWorker": 28,
				"./support": 30,
				"./utils": 32
			}],
			32: [function(t, e, n) {
				"use strict";

				function i(t) {
					var e = null;
					return e = l.uint8array ? new Uint8Array(t.length) : new Array(t.length), a(t, e)
				}

				function r(t) {
					return t
				}

				function a(t, e) {
					for(var n = 0; n < t.length; ++n) e[n] = 255 & t.charCodeAt(n);
					return e
				}

				function o(t) {
					var e = 65536,
						i = n.getTypeOf(t),
						r = !0;
					if("uint8array" === i ? r = p.applyCanBeUsed.uint8array : "nodebuffer" === i && (r = p.applyCanBeUsed.nodebuffer), r)
						for(; e > 1;) try {
							return p.stringifyByChunk(t, i, e)
						} catch(t) {
							e = Math.floor(e / 2)
						}
					return p.stringifyByChar(t)
				}

				function s(t, e) {
					for(var n = 0; n < t.length; n++) e[n] = t[n];
					return e
				}
				var l = t("./support"),
					c = t("./base64"),
					h = t("./nodejsUtils"),
					u = t("core-js/library/fn/set-immediate"),
					f = t("./external");
				n.newBlob = function(t, e) {
					n.checkSupport("blob");
					try {
						return new Blob([t], {
							type: e
						})
					} catch(n) {
						try {
							var i = new(self.BlobBuilder || self.WebKitBlobBuilder || self.MozBlobBuilder || self.MSBlobBuilder);
							return i.append(t), i.getBlob(e)
						} catch(t) {
							throw new Error("Bug : can't construct the Blob.")
						}
					}
				};
				var p = {
					stringifyByChunk: function(t, e, n) {
						var i = [],
							r = 0,
							a = t.length;
						if(a <= n) return String.fromCharCode.apply(null, t);
						for(; r < a;) "array" === e || "nodebuffer" === e ? i.push(String.fromCharCode.apply(null, t.slice(r, Math.min(r + n, a)))) : i.push(String.fromCharCode.apply(null, t.subarray(r, Math.min(r + n, a)))), r += n;
						return i.join("")
					},
					stringifyByChar: function(t) {
						for(var e = "", n = 0; n < t.length; n++) e += String.fromCharCode(t[n]);
						return e
					},
					applyCanBeUsed: {
						uint8array: function() {
							try {
								return l.uint8array && 1 === String.fromCharCode.apply(null, new Uint8Array(1)).length
							} catch(t) {
								return !1
							}
						}(),
						nodebuffer: function() {
							try {
								return l.nodebuffer && 1 === String.fromCharCode.apply(null, h.allocBuffer(1)).length
							} catch(t) {
								return !1
							}
						}()
					}
				};
				n.applyFromCharCode = o;
				var d = {};
				d.string = {
					string: r,
					array: function(t) {
						return a(t, new Array(t.length))
					},
					arraybuffer: function(t) {
						return d.string.uint8array(t).buffer
					},
					uint8array: function(t) {
						return a(t, new Uint8Array(t.length))
					},
					nodebuffer: function(t) {
						return a(t, h.allocBuffer(t.length))
					}
				}, d.array = {
					string: o,
					array: r,
					arraybuffer: function(t) {
						return new Uint8Array(t).buffer
					},
					uint8array: function(t) {
						return new Uint8Array(t)
					},
					nodebuffer: function(t) {
						return h.newBufferFrom(t)
					}
				}, d.arraybuffer = {
					string: function(t) {
						return o(new Uint8Array(t))
					},
					array: function(t) {
						return s(new Uint8Array(t), new Array(t.byteLength))
					},
					arraybuffer: r,
					uint8array: function(t) {
						return new Uint8Array(t)
					},
					nodebuffer: function(t) {
						return h.newBufferFrom(new Uint8Array(t))
					}
				}, d.uint8array = {
					string: o,
					array: function(t) {
						return s(t, new Array(t.length))
					},
					arraybuffer: function(t) {
						return t.buffer
					},
					uint8array: r,
					nodebuffer: function(t) {
						return h.newBufferFrom(t)
					}
				}, d.nodebuffer = {
					string: o,
					array: function(t) {
						return s(t, new Array(t.length))
					},
					arraybuffer: function(t) {
						return d.nodebuffer.uint8array(t).buffer
					},
					uint8array: function(t) {
						return s(t, new Uint8Array(t.length))
					},
					nodebuffer: r
				}, n.transformTo = function(t, e) {
					if(e || (e = ""), !t) return e;
					n.checkSupport(t);
					var i = n.getTypeOf(e);
					return d[i][t](e)
				}, n.getTypeOf = function(t) {
					return "string" == typeof t ? "string" : "[object Array]" === Object.prototype.toString.call(t) ? "array" : l.nodebuffer && h.isBuffer(t) ? "nodebuffer" : l.uint8array && t instanceof Uint8Array ? "uint8array" : l.arraybuffer && t instanceof ArrayBuffer ? "arraybuffer" : void 0
				}, n.checkSupport = function(t) {
					if(!l[t.toLowerCase()]) throw new Error(t + " is not supported by this platform")
				}, n.MAX_VALUE_16BITS = 65535, n.MAX_VALUE_32BITS = -1, n.pretty = function(t) {
					var e, n, i = "";
					for(n = 0; n < (t || "").length; n++) e = t.charCodeAt(n), i += "\\x" + (e < 16 ? "0" : "") + e.toString(16).toUpperCase();
					return i
				}, n.delay = function(t, e, n) {
					u(function() {
						t.apply(n || null, e || [])
					})
				}, n.inherits = function(t, e) {
					var n = function() {};
					n.prototype = e.prototype, t.prototype = new n
				}, n.extend = function() {
					var t, e, n = {};
					for(t = 0; t < arguments.length; t++)
						for(e in arguments[t]) arguments[t].hasOwnProperty(e) && void 0 === n[e] && (n[e] = arguments[t][e]);
					return n
				}, n.prepareContent = function(t, e, r, a, o) {
					return f.Promise.resolve(e).then(function(t) {
						return l.blob && (t instanceof Blob || -1 !== ["[object File]", "[object Blob]"].indexOf(Object.prototype.toString.call(t))) && "undefined" != typeof FileReader ? new f.Promise(function(e, n) {
							var i = new FileReader;
							i.onload = function(t) {
								e(t.target.result)
							}, i.onerror = function(t) {
								n(t.target.error)
							}, i.readAsArrayBuffer(t)
						}) : t
					}).then(function(e) {
						var s = n.getTypeOf(e);
						return s ? ("arraybuffer" === s ? e = n.transformTo("uint8array", e) : "string" === s && (o ? e = c.decode(e) : r && !0 !== a && (e = i(e))), e) : f.Promise.reject(new Error("Can't read the data of '" + t + "'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))
					})
				}
			}, {
				"./base64": 1,
				"./external": 6,
				"./nodejsUtils": 14,
				"./support": 30,
				"core-js/library/fn/set-immediate": 36
			}],
			33: [function(t, e, n) {
				"use strict";

				function i(t) {
					this.files = [], this.loadOptions = t
				}
				var r = t("./reader/readerFor"),
					a = t("./utils"),
					o = t("./signature"),
					s = t("./zipEntry"),
					l = (t("./utf8"), t("./support"));
				i.prototype = {
					checkSignature: function(t) {
						if(!this.reader.readAndCheckSignature(t)) {
							this.reader.index -= 4;
							var e = this.reader.readString(4);
							throw new Error("Corrupted zip or bug: unexpected signature (" + a.pretty(e) + ", expected " + a.pretty(t) + ")")
						}
					},
					isSignature: function(t, e) {
						var n = this.reader.index;
						this.reader.setIndex(t);
						var i = this.reader.readString(4) === e;
						return this.reader.setIndex(n), i
					},
					readBlockEndOfCentral: function() {
						this.diskNumber = this.reader.readInt(2), this.diskWithCentralDirrt = this.reader.readInt(2), this.centralDirRecordsOnThisDisk = this.reader.readInt(2), this.centralDirRecords = this.reader.readInt(2), this.centralDirSize = this.reader.readInt(4), this.centralDirOffset = this.reader.readInt(4), this.zipCommentLength = this.reader.readInt(2);
						var t = this.reader.readData(this.zipCommentLength),
							e = l.uint8array ? "uint8array" : "array",
							n = a.transformTo(e, t);
						this.zipComment = this.loadOptions.decodeFileName(n)
					},
					readBlockZip64EndOfCentral: function() {
						this.zip64EndOfCentralSize = this.reader.readInt(8), this.reader.skip(4), this.diskNumber = this.reader.readInt(4), this.diskWithCentralDirrt = this.reader.readInt(4), this.centralDirRecordsOnThisDisk = this.reader.readInt(8), this.centralDirRecords = this.reader.readInt(8), this.centralDirSize = this.reader.readInt(8), this.centralDirOffset = this.reader.readInt(8), this.zip64ExtensibleData = {};
						for(var t, e, n, i = this.zip64EndOfCentralSize - 44; 0 < i;) t = this.reader.readInt(2), e = this.reader.readInt(4), n = this.reader.readData(e), this.zip64ExtensibleData[t] = {
							id: t,
							length: e,
							value: n
						}
					},
					readBlockZip64EndOfCentralLocator: function() {
						if(this.diskWithZip64CentralDirrt = this.reader.readInt(4), this.relativeOffsetEndOfZip64CentralDir = this.reader.readInt(8), this.disksCount = this.reader.readInt(4), this.disksCount > 1) throw new Error("Multi-volumes zip are not supported")
					},
					readLocalFiles: function() {
						var t, e;
						for(t = 0; t < this.files.length; t++) e = this.files[t], this.reader.setIndex(e.localHeaderOffset), this.checkSignature(o.LOCAL_FILE_HEADER), e.readLocalPart(this.reader), e.handleUTF8(), e.processAttributes()
					},
					readCentralDir: function() {
						var t;
						for(this.reader.setIndex(this.centralDirOffset); this.reader.readAndCheckSignature(o.CENTRAL_FILE_HEADER);)(t = new s({
							zip64: this.zip64
						}, this.loadOptions)).readCentralPart(this.reader), this.files.push(t);
						if(this.centralDirRecords !== this.files.length && 0 !== this.centralDirRecords && 0 === this.files.length) throw new Error("Corrupted zip or bug: expected " + this.centralDirRecords + " records in central dir, got " + this.files.length)
					},
					readEndOfCentral: function() {
						var t = this.reader.lastIndexOfSignature(o.CENTRAL_DIRECTORY_END);
						if(t < 0) throw !this.isSignature(0, o.LOCAL_FILE_HEADER) ? new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html") : new Error("Corrupted zip: can't find end of central directory");
						this.reader.setIndex(t);
						var e = t;
						if(this.checkSignature(o.CENTRAL_DIRECTORY_END), this.readBlockEndOfCentral(), this.diskNumber === a.MAX_VALUE_16BITS || this.diskWithCentralDirrt === a.MAX_VALUE_16BITS || this.centralDirRecordsOnThisDisk === a.MAX_VALUE_16BITS || this.centralDirRecords === a.MAX_VALUE_16BITS || this.centralDirSize === a.MAX_VALUE_32BITS || this.centralDirOffset === a.MAX_VALUE_32BITS) {
							if(this.zip64 = !0, (t = this.reader.lastIndexOfSignature(o.ZIP64_CENTRAL_DIRECTORY_LOCATOR)) < 0) throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");
							if(this.reader.setIndex(t), this.checkSignature(o.ZIP64_CENTRAL_DIRECTORY_LOCATOR), this.readBlockZip64EndOfCentralLocator(), !this.isSignature(this.relativeOffsetEndOfZip64CentralDir, o.ZIP64_CENTRAL_DIRECTORY_END) && (this.relativeOffsetEndOfZip64CentralDir = this.reader.lastIndexOfSignature(o.ZIP64_CENTRAL_DIRECTORY_END), this.relativeOffsetEndOfZip64CentralDir < 0)) throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");
							this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir), this.checkSignature(o.ZIP64_CENTRAL_DIRECTORY_END), this.readBlockZip64EndOfCentral()
						}
						var n = this.centralDirOffset + this.centralDirSize;
						this.zip64 && (n += 20, n += 12 + this.zip64EndOfCentralSize);
						var i = e - n;
						if(i > 0) this.isSignature(e, o.CENTRAL_FILE_HEADER) || (this.reader.zero = i);
						else if(i < 0) throw new Error("Corrupted zip: missing " + Math.abs(i) + " bytes.")
					},
					prepareReader: function(t) {
						this.reader = r(t)
					},
					load: function(t) {
						this.prepareReader(t), this.readEndOfCentral(), this.readCentralDir(), this.readLocalFiles()
					}
				}, e.exports = i
			}, {
				"./reader/readerFor": 22,
				"./signature": 23,
				"./support": 30,
				"./utf8": 31,
				"./utils": 32,
				"./zipEntry": 34
			}],
			34: [function(t, e, n) {
				"use strict";

				function i(t, e) {
					this.options = t, this.loadOptions = e
				}
				var r = t("./reader/readerFor"),
					a = t("./utils"),
					o = t("./compressedObject"),
					s = t("./crc32"),
					l = t("./utf8"),
					c = t("./compressions"),
					h = t("./support"),
					u = function(t) {
						for(var e in c)
							if(c.hasOwnProperty(e) && c[e].magic === t) return c[e];
						return null
					};
				i.prototype = {
					isEncrypted: function() {
						return 1 == (1 & this.bitFlag)
					},
					useUTF8: function() {
						return 2048 == (2048 & this.bitFlag)
					},
					readLocalPart: function(t) {
						var e, n;
						if(t.skip(22), this.fileNameLength = t.readInt(2), n = t.readInt(2), this.fileName = t.readData(this.fileNameLength), t.skip(n), -1 === this.compressedSize || -1 === this.uncompressedSize) throw new Error("Bug or corrupted zip : didn't get enough informations from the central directory (compressedSize === -1 || uncompressedSize === -1)");
						if(null === (e = u(this.compressionMethod))) throw new Error("Corrupted zip : compression " + a.pretty(this.compressionMethod) + " unknown (inner file : " + a.transformTo("string", this.fileName) + ")");
						this.decompressed = new o(this.compressedSize, this.uncompressedSize, this.crc32, e, t.readData(this.compressedSize))
					},
					readCentralPart: function(t) {
						this.versionMadeBy = t.readInt(2), t.skip(2), this.bitFlag = t.readInt(2), this.compressionMethod = t.readString(2), this.date = t.readDate(), this.crc32 = t.readInt(4), this.compressedSize = t.readInt(4), this.uncompressedSize = t.readInt(4);
						var e = t.readInt(2);
						if(this.extraFieldsLength = t.readInt(2), this.fileCommentLength = t.readInt(2), this.diskNumberrt = t.readInt(2), this.internalFileAttributes = t.readInt(2), this.externalFileAttributes = t.readInt(4), this.localHeaderOffset = t.readInt(4), this.isEncrypted()) throw new Error("Encrypted zip are not supported");
						t.skip(e), this.readExtraFields(t), this.parseZIP64ExtraField(t), this.fileComment = t.readData(this.fileCommentLength)
					},
					processAttributes: function() {
						this.unixPermissions = null, this.dosPermissions = null;
						var t = this.versionMadeBy >> 8;
						this.dir = !!(16 & this.externalFileAttributes), 0 === t && (this.dosPermissions = 63 & this.externalFileAttributes), 3 === t && (this.unixPermissions = this.externalFileAttributes >> 16 & 65535), this.dir || "/" !== this.fileNameStr.slice(-1) || (this.dir = !0)
					},
					parseZIP64ExtraField: function(t) {
						if(this.extraFields[1]) {
							var e = r(this.extraFields[1].value);
							this.uncompressedSize === a.MAX_VALUE_32BITS && (this.uncompressedSize = e.readInt(8)), this.compressedSize === a.MAX_VALUE_32BITS && (this.compressedSize = e.readInt(8)), this.localHeaderOffset === a.MAX_VALUE_32BITS && (this.localHeaderOffset = e.readInt(8)), this.diskNumberrt === a.MAX_VALUE_32BITS && (this.diskNumberrt = e.readInt(4))
						}
					},
					readExtraFields: function(t) {
						var e, n, i, r = t.index + this.extraFieldsLength;
						for(this.extraFields || (this.extraFields = {}); t.index < r;) e = t.readInt(2), n = t.readInt(2), i = t.readData(n), this.extraFields[e] = {
							id: e,
							length: n,
							value: i
						}
					},
					handleUTF8: function() {
						var t = h.uint8array ? "uint8array" : "array";
						if(this.useUTF8()) this.fileNameStr = l.utf8decode(this.fileName), this.fileCommentStr = l.utf8decode(this.fileComment);
						else {
							var e = this.findExtraFieldUnicodePath();
							if(null !== e) this.fileNameStr = e;
							else {
								var n = a.transformTo(t, this.fileName);
								this.fileNameStr = this.loadOptions.decodeFileName(n)
							}
							var i = this.findExtraFieldUnicodeComment();
							if(null !== i) this.fileCommentStr = i;
							else {
								var r = a.transformTo(t, this.fileComment);
								this.fileCommentStr = this.loadOptions.decodeFileName(r)
							}
						}
					},
					findExtraFieldUnicodePath: function() {
						var t = this.extraFields[28789];
						if(t) {
							var e = r(t.value);
							return 1 !== e.readInt(1) ? null : s(this.fileName) !== e.readInt(4) ? null : l.utf8decode(e.readData(t.length - 5))
						}
						return null
					},
					findExtraFieldUnicodeComment: function() {
						var t = this.extraFields[25461];
						if(t) {
							var e = r(t.value);
							return 1 !== e.readInt(1) ? null : s(this.fileComment) !== e.readInt(4) ? null : l.utf8decode(e.readData(t.length - 5))
						}
						return null
					}
				}, e.exports = i
			}, {
				"./compressedObject": 2,
				"./compressions": 3,
				"./crc32": 4,
				"./reader/readerFor": 22,
				"./support": 30,
				"./utf8": 31,
				"./utils": 32
			}],
			35: [function(t, e, n) {
				"use strict";
				var i = t("./stream/StreamHelper"),
					r = t("./stream/DataWorker"),
					a = t("./utf8"),
					o = t("./compressedObject"),
					s = t("./stream/GenericWorker"),
					l = function(t, e, n) {
						this.name = t, this.dir = n.dir, this.date = n.date, this.comment = n.comment, this.unixPermissions = n.unixPermissions, this.dosPermissions = n.dosPermissions, this._data = e, this._dataBinary = n.binary, this.options = {
							compression: n.compression,
							compressionOptions: n.compressionOptions
						}
					};
				l.prototype = {
					internalStream: function(t) {
						var e = null,
							n = "string";
						try {
							if(!t) throw new Error("No output type specified.");
							var r = "string" === (n = t.toLowerCase()) || "text" === n;
							"binarystring" !== n && "text" !== n || (n = "string"), e = this._decompressWorker();
							var o = !this._dataBinary;
							o && !r && (e = e.pipe(new a.Utf8EncodeWorker)), !o && r && (e = e.pipe(new a.Utf8DecodeWorker))
						} catch(t) {
							(e = new s("error")).error(t)
						}
						return new i(e, n, "")
					},
					async: function(t, e) {
						return this.internalStream(t).accumulate(e)
					},
					nodeStream: function(t, e) {
						return this.internalStream(t || "nodebuffer").toNodejsStream(e)
					},
					_compressWorker: function(t, e) {
						if(this._data instanceof o && this._data.compression.magic === t.magic) return this._data.getCompressedWorker();
						var n = this._decompressWorker();
						return this._dataBinary || (n = n.pipe(new a.Utf8EncodeWorker)), o.createWorkerFrom(n, t, e)
					},
					_decompressWorker: function() {
						return this._data instanceof o ? this._data.getContentWorker() : this._data instanceof s ? this._data : new r(this._data)
					}
				};
				for(var c = ["asText", "asBinary", "asNodeBuffer", "asUint8Array", "asArrayBuffer"], h = 0; h < c.length; h++) l.prototype[c[h]] = function() {
					throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")
				};
				e.exports = l
			}, {
				"./compressedObject": 2,
				"./stream/DataWorker": 27,
				"./stream/GenericWorker": 28,
				"./stream/StreamHelper": 29,
				"./utf8": 31
			}],
			36: [function(t, e, n) {
				t("../modules/web.immediate"), e.exports = t("../modules/_core").setImmediate
			}, {
				"../modules/_core": 40,
				"../modules/web.immediate": 56
			}],
			37: [function(t, e, n) {
				e.exports = function(t) {
					if("function" != typeof t) throw TypeError(t + " is not a function!");
					return t
				}
			}, {}],
			38: [function(t, e, n) {
				var i = t("./_is-object");
				e.exports = function(t) {
					if(!i(t)) throw TypeError(t + " is not an object!");
					return t
				}
			}, {
				"./_is-object": 51
			}],
			39: [function(t, e, n) {
				var i = {}.toString;
				e.exports = function(t) {
					return i.call(t).slice(8, -1)
				}
			}, {}],
			40: [function(t, e, n) {
				var i = e.exports = {
					version: "2.3.0"
				};
				"number" == typeof __e && (__e = i)
			}, {}],
			41: [function(t, e, n) {
				var i = t("./_a-function");
				e.exports = function(t, e, n) {
					if(i(t), void 0 === e) return t;
					switch(n) {
						case 1:
							return function(n) {
								return t.call(e, n)
							};
						case 2:
							return function(n, i) {
								return t.call(e, n, i)
							};
						case 3:
							return function(n, i, r) {
								return t.call(e, n, i, r)
							}
					}
					return function() {
						return t.apply(e, arguments)
					}
				}
			}, {
				"./_a-function": 37
			}],
			42: [function(t, e, n) {
				e.exports = !t("./_fails")(function() {
					return 7 != Object.defineProperty({}, "a", {
						get: function() {
							return 7
						}
					}).a
				})
			}, {
				"./_fails": 45
			}],
			43: [function(t, e, n) {
				var i = t("./_is-object"),
					r = t("./_global").document,
					a = i(r) && i(r.createElement);
				e.exports = function(t) {
					return a ? r.createElement(t) : {}
				}
			}, {
				"./_global": 46,
				"./_is-object": 51
			}],
			44: [function(t, e, n) {
				var i = t("./_global"),
					r = t("./_core"),
					a = t("./_ctx"),
					o = t("./_hide"),
					s = "prototype",
					l = function(t, e, n) {
						var c, h, u, f = t & l.F,
							p = t & l.G,
							d = t & l.S,
							m = t & l.P,
							g = t & l.B,
							v = t & l.W,
							_ = p ? r : r[e] || (r[e] = {}),
							y = _[s],
							x = p ? i : d ? i[e] : (i[e] || {})[s];
						p && (n = e);
						for(c in n)(h = !f && x && void 0 !== x[c]) && c in _ || (u = h ? x[c] : n[c], _[c] = p && "function" != typeof x[c] ? n[c] : g && h ? a(u, i) : v && x[c] == u ? function(t) {
							var e = function(e, n, i) {
								if(this instanceof t) {
									switch(arguments.length) {
										case 0:
											return new t;
										case 1:
											return new t(e);
										case 2:
											return new t(e, n)
									}
									return new t(e, n, i)
								}
								return t.apply(this, arguments)
							};
							return e[s] = t[s], e
						}(u) : m && "function" == typeof u ? a(Function.call, u) : u, m && ((_.virtual || (_.virtual = {}))[c] = u, t & l.R && y && !y[c] && o(y, c, u)))
					};
				l.F = 1, l.G = 2, l.S = 4, l.P = 8, l.B = 16, l.W = 32, l.U = 64, l.R = 128, e.exports = l
			}, {
				"./_core": 40,
				"./_ctx": 41,
				"./_global": 46,
				"./_hide": 47
			}],
			45: [function(t, e, n) {
				e.exports = function(t) {
					try {
						return !!t()
					} catch(t) {
						return !0
					}
				}
			}, {}],
			46: [function(t, e, n) {
				var i = e.exports = "undefined" != typeof window && window.Math == Math ? window : "undefined" != typeof self && self.Math == Math ? self : Function("return this")();
				"number" == typeof __g && (__g = i)
			}, {}],
			47: [function(t, e, n) {
				var i = t("./_object-dp"),
					r = t("./_property-desc");
				e.exports = t("./_descriptors") ? function(t, e, n) {
					return i.f(t, e, r(1, n))
				} : function(t, e, n) {
					return t[e] = n, t
				}
			}, {
				"./_descriptors": 42,
				"./_object-dp": 52,
				"./_property-desc": 53
			}],
			48: [function(t, e, n) {
				e.exports = t("./_global").document && document.documentElement
			}, {
				"./_global": 46
			}],
			49: [function(t, e, n) {
				e.exports = !t("./_descriptors") && !t("./_fails")(function() {
					return 7 != Object.defineProperty(t("./_dom-create")("div"), "a", {
						get: function() {
							return 7
						}
					}).a
				})
			}, {
				"./_descriptors": 42,
				"./_dom-create": 43,
				"./_fails": 45
			}],
			50: [function(t, e, n) {
				e.exports = function(t, e, n) {
					var i = void 0 === n;
					switch(e.length) {
						case 0:
							return i ? t() : t.call(n);
						case 1:
							return i ? t(e[0]) : t.call(n, e[0]);
						case 2:
							return i ? t(e[0], e[1]) : t.call(n, e[0], e[1]);
						case 3:
							return i ? t(e[0], e[1], e[2]) : t.call(n, e[0], e[1], e[2]);
						case 4:
							return i ? t(e[0], e[1], e[2], e[3]) : t.call(n, e[0], e[1], e[2], e[3])
					}
					return t.apply(n, e)
				}
			}, {}],
			51: [function(t, e, n) {
				e.exports = function(t) {
					return "object" == typeof t ? null !== t : "function" == typeof t
				}
			}, {}],
			52: [function(t, e, n) {
				var i = t("./_an-object"),
					r = t("./_ie8-dom-define"),
					a = t("./_to-primitive"),
					o = Object.defineProperty;
				n.f = t("./_descriptors") ? Object.defineProperty : function(t, e, n) {
					if(i(t), e = a(e, !0), i(n), r) try {
						return o(t, e, n)
					} catch(t) {}
					if("get" in n || "set" in n) throw TypeError("Accessors not supported!");
					return "value" in n && (t[e] = n.value), t
				}
			}, {
				"./_an-object": 38,
				"./_descriptors": 42,
				"./_ie8-dom-define": 49,
				"./_to-primitive": 55
			}],
			53: [function(t, e, n) {
				e.exports = function(t, e) {
					return {
						enumerable: !(1 & t),
						configurable: !(2 & t),
						writable: !(4 & t),
						value: e
					}
				}
			}, {}],
			54: [function(t, e, n) {
				var i, r, a, o = t("./_ctx"),
					s = t("./_invoke"),
					l = t("./_html"),
					c = t("./_dom-create"),
					h = t("./_global"),
					u = h.process,
					f = h.setImmediate,
					p = h.clearImmediate,
					d = h.MessageChannel,
					m = 0,
					g = {},
					v = "onreadystatechange",
					_ = function() {
						var t = +this;
						if(g.hasOwnProperty(t)) {
							var e = g[t];
							delete g[t], e()
						}
					},
					y = function(t) {
						_.call(t.data)
					};
				f && p || (f = function(t) {
					for(var e = [], n = 1; arguments.length > n;) e.push(arguments[n++]);
					return g[++m] = function() {
						s("function" == typeof t ? t : Function(t), e)
					}, i(m), m
				}, p = function(t) {
					delete g[t]
				}, "process" == t("./_cof")(u) ? i = function(t) {
					u.nextTick(o(_, t, 1))
				} : d ? (r = new d, a = r.port2, r.port1.onmessage = y, i = o(a.postMessage, a, 1)) : h.addEventListener && "function" == typeof postMessage && !h.importScripts ? (i = function(t) {
					h.postMessage(t + "", "*")
				}, h.addEventListener("message", y, !1)) : i = v in c("script") ? function(t) {
					l.appendChild(c("script"))[v] = function() {
						l.removeChild(this), _.call(t)
					}
				} : function(t) {
					setTimeout(o(_, t, 1), 0)
				}), e.exports = {
					set: f,
					clear: p
				}
			}, {
				"./_cof": 39,
				"./_ctx": 41,
				"./_dom-create": 43,
				"./_global": 46,
				"./_html": 48,
				"./_invoke": 50
			}],
			55: [function(t, e, n) {
				var i = t("./_is-object");
				e.exports = function(t, e) {
					if(!i(t)) return t;
					var n, r;
					if(e && "function" == typeof(n = t.toString) && !i(r = n.call(t))) return r;
					if("function" == typeof(n = t.valueOf) && !i(r = n.call(t))) return r;
					if(!e && "function" == typeof(n = t.toString) && !i(r = n.call(t))) return r;
					throw TypeError("Can't convert object to primitive value")
				}
			}, {
				"./_is-object": 51
			}],
			56: [function(t, e, n) {
				var i = t("./_export"),
					r = t("./_task");
				i(i.G + i.B, {
					setImmediate: r.set,
					clearImmediate: r.clear
				})
			}, {
				"./_export": 44,
				"./_task": 54
			}],
			57: [function(t, e, n) {
				(function(t) {
					"use strict";

					function n() {
						c = !0;
						for(var t, e, n = h.length; n;) {
							for(e = h, h = [], t = -1; ++t < n;) e[t]();
							n = h.length
						}
						c = !1
					}
					var i, r = t.MutationObserver || t.WebKitMutationObserver;
					if(r) {
						var a = 0,
							o = new r(n),
							s = t.document.createTextNode("");
						o.observe(s, {
							characterData: !0
						}), i = function() {
							s.data = a = ++a % 2
						}
					} else if(t.setImmediate || void 0 === t.MessageChannel) i = "document" in t && "onreadystatechange" in t.document.createElement("script") ? function() {
						var e = t.document.createElement("script");
						e.onreadystatechange = function() {
							n(), e.onreadystatechange = null, e.parentNode.removeChild(e), e = null
						}, t.document.documentElement.appendChild(e)
					} : function() {
						setTimeout(n, 0)
					};
					else {
						var l = new t.MessageChannel;
						l.port1.onmessage = n, i = function() {
							l.port2.postMessage(0)
						}
					}
					var c, h = [];
					e.exports = function(t) {
						1 !== h.push(t) || c || i()
					}
				}).call(this, "undefined" != typeof global ? global : "undefined" != typeof self ? self : "undefined" != typeof window ? window : {})
			}, {}],
			58: [function(t, e, n) {
				"use strict";

				function i() {}

				function r(t) {
					if("function" != typeof t) throw new TypeError("resolver must be a function");
					this.state = d, this.queue = [], this.outcome = void 0, t !== i && l(this, t)
				}

				function a(t, e, n) {
					this.promise = t, "function" == typeof e && (this.onFulfilled = e, this.callFulfilled = this.otherCallFulfilled), "function" == typeof n && (this.onRejected = n, this.callRejected = this.otherCallRejected)
				}

				function o(t, e, n) {
					h(function() {
						var i;
						try {
							i = e(n)
						} catch(e) {
							return u.reject(t, e)
						}
						i === t ? u.reject(t, new TypeError("Cannot resolve promise with itself")) : u.resolve(t, i)
					})
				}

				function s(t) {
					var e = t && t.then;
					if(t && ("object" == typeof t || "function" == typeof t) && "function" == typeof e) return function() {
						e.apply(t, arguments)
					}
				}

				function l(t, e) {
					function n(e) {
						r || (r = !0, u.reject(t, e))
					}

					function i(e) {
						r || (r = !0, u.resolve(t, e))
					}
					var r = !1,
						a = c(function() {
							e(i, n)
						});
					"error" === a.status && n(a.value)
				}

				function c(t, e) {
					var n = {};
					try {
						n.value = t(e), n.status = "success"
					} catch(t) {
						n.status = "error", n.value = t
					}
					return n
				}
				var h = t("immediate"),
					u = {},
					f = ["REJECTED"],
					p = ["FULFILLED"],
					d = ["PENDING"];
				e.exports = r, r.prototype.catch = function(t) {
					return this.then(null, t)
				}, r.prototype.then = function(t, e) {
					if("function" != typeof t && this.state === p || "function" != typeof e && this.state === f) return this;
					var n = new this.constructor(i);
					return this.state !== d ? o(n, this.state === p ? t : e, this.outcome) : this.queue.push(new a(n, t, e)), n
				}, a.prototype.callFulfilled = function(t) {
					u.resolve(this.promise, t)
				}, a.prototype.otherCallFulfilled = function(t) {
					o(this.promise, this.onFulfilled, t)
				}, a.prototype.callRejected = function(t) {
					u.reject(this.promise, t)
				}, a.prototype.otherCallRejected = function(t) {
					o(this.promise, this.onRejected, t)
				}, u.resolve = function(t, e) {
					var n = c(s, e);
					if("error" === n.status) return u.reject(t, n.value);
					var i = n.value;
					if(i) l(t, i);
					else {
						t.state = p, t.outcome = e;
						for(var r = -1, a = t.queue.length; ++r < a;) t.queue[r].callFulfilled(e)
					}
					return t
				}, u.reject = function(t, e) {
					t.state = f, t.outcome = e;
					for(var n = -1, i = t.queue.length; ++n < i;) t.queue[n].callRejected(e);
					return t
				}, r.resolve = function(t) {
					return t instanceof this ? t : u.resolve(new this(i), t)
				}, r.reject = function(t) {
					var e = new this(i);
					return u.reject(e, t)
				}, r.all = function(t) {
					var e = this;
					if("[object Array]" !== Object.prototype.toString.call(t)) return this.reject(new TypeError("must be an array"));
					var n = t.length,
						r = !1;
					if(!n) return this.resolve([]);
					for(var a = new Array(n), o = 0, s = -1, l = new this(i); ++s < n;) ! function(t, i) {
						e.resolve(t).then(function(t) {
							a[i] = t, ++o !== n || r || (r = !0, u.resolve(l, a))
						}, function(t) {
							r || (r = !0, u.reject(l, t))
						})
					}(t[s], s);
					return l
				}, r.race = function(t) {
					var e = this;
					if("[object Array]" !== Object.prototype.toString.call(t)) return this.reject(new TypeError("must be an array"));
					var n = t.length,
						r = !1;
					if(!n) return this.resolve([]);
					for(var a = -1, o = new this(i); ++a < n;) ! function(t) {
						e.resolve(t).then(function(t) {
							r || (r = !0, u.resolve(o, t))
						}, function(t) {
							r || (r = !0, u.reject(o, t))
						})
					}(t[a]);
					return o
				}
			}, {
				immediate: 57
			}],
			59: [function(t, e, n) {
				"use strict";
				var i = {};
				(0, t("./lib/utils/common").assign)(i, t("./lib/deflate"), t("./lib/inflate"), t("./lib/zlib/constants")), e.exports = i
			}, {
				"./lib/deflate": 60,
				"./lib/inflate": 61,
				"./lib/utils/common": 62,
				"./lib/zlib/constants": 65
			}],
			60: [function(t, e, n) {
				"use strict";

				function i(t) {
					if(!(this instanceof i)) return new i(t);
					this.options = o.assign({
						level: f,
						method: d,
						chunkSize: 16384,
						windowBits: 15,
						memLevel: 8,
						strategy: p,
						to: ""
					}, t || {});
					var e = this.options;
					e.raw && e.windowBits > 0 ? e.windowBits = -e.windowBits : e.gzip && e.windowBits > 0 && e.windowBits < 16 && (e.windowBits += 16), this.err = 0, this.msg = "", this.ended = !1, this.chunks = [], this.strm = new c, this.strm.avail_out = 0;
					var n = a.deflateInit2(this.strm, e.level, e.method, e.windowBits, e.memLevel, e.strategy);
					if(n !== u) throw new Error(l[n]);
					if(e.header && a.deflateSetHeader(this.strm, e.header), e.dictionary) {
						var r;
						if(r = "string" == typeof e.dictionary ? s.string2buf(e.dictionary) : "[object ArrayBuffer]" === h.call(e.dictionary) ? new Uint8Array(e.dictionary) : e.dictionary, (n = a.deflateSetDictionary(this.strm, r)) !== u) throw new Error(l[n]);
						this._dict_set = !0
					}
				}

				function r(t, e) {
					var n = new i(e);
					if(n.push(t, !0), n.err) throw n.msg || l[n.err];
					return n.result
				}
				var a = t("./zlib/deflate"),
					o = t("./utils/common"),
					s = t("./utils/strings"),
					l = t("./zlib/messages"),
					c = t("./zlib/zstream"),
					h = Object.prototype.toString,
					u = 0,
					f = -1,
					p = 0,
					d = 8;
				i.prototype.push = function(t, e) {
					var n, i, r = this.strm,
						l = this.options.chunkSize;
					if(this.ended) return !1;
					i = e === ~~e ? e : !0 === e ? 4 : 0, "string" == typeof t ? r.input = s.string2buf(t) : "[object ArrayBuffer]" === h.call(t) ? r.input = new Uint8Array(t) : r.input = t, r.next_in = 0, r.avail_in = r.input.length;
					do {
						if(0 === r.avail_out && (r.output = new o.Buf8(l), r.next_out = 0, r.avail_out = l), 1 !== (n = a.deflate(r, i)) && n !== u) return this.onEnd(n), this.ended = !0, !1;
						0 !== r.avail_out && (0 !== r.avail_in || 4 !== i && 2 !== i) || ("string" === this.options.to ? this.onData(s.buf2binstring(o.shrinkBuf(r.output, r.next_out))) : this.onData(o.shrinkBuf(r.output, r.next_out)))
					} while ((r.avail_in > 0 || 0 === r.avail_out) && 1 !== n);
					return 4 === i ? (n = a.deflateEnd(this.strm), this.onEnd(n), this.ended = !0, n === u) : 2 !== i || (this.onEnd(u), r.avail_out = 0, !0)
				}, i.prototype.onData = function(t) {
					this.chunks.push(t)
				}, i.prototype.onEnd = function(t) {
					t === u && ("string" === this.options.to ? this.result = this.chunks.join("") : this.result = o.flattenChunks(this.chunks)), this.chunks = [], this.err = t, this.msg = this.strm.msg
				}, n.Deflate = i, n.deflate = r, n.deflateRaw = function(t, e) {
					return e = e || {}, e.raw = !0, r(t, e)
				}, n.gzip = function(t, e) {
					return e = e || {}, e.gzip = !0, r(t, e)
				}
			}, {
				"./utils/common": 62,
				"./utils/strings": 63,
				"./zlib/deflate": 67,
				"./zlib/messages": 72,
				"./zlib/zstream": 74
			}],
			61: [function(t, e, n) {
				"use strict";

				function i(t) {
					if(!(this instanceof i)) return new i(t);
					this.options = o.assign({
						chunkSize: 16384,
						windowBits: 0,
						to: ""
					}, t || {});
					var e = this.options;
					e.raw && e.windowBits >= 0 && e.windowBits < 16 && (e.windowBits = -e.windowBits, 0 === e.windowBits && (e.windowBits = -15)), !(e.windowBits >= 0 && e.windowBits < 16) || t && t.windowBits || (e.windowBits += 32), e.windowBits > 15 && e.windowBits < 48 && 0 == (15 & e.windowBits) && (e.windowBits |= 15), this.err = 0, this.msg = "", this.ended = !1, this.chunks = [], this.strm = new h, this.strm.avail_out = 0;
					var n = a.inflateInit2(this.strm, e.windowBits);
					if(n !== l.Z_OK) throw new Error(c[n]);
					this.header = new u, a.inflateGetHeader(this.strm, this.header)
				}

				function r(t, e) {
					var n = new i(e);
					if(n.push(t, !0), n.err) throw n.msg || c[n.err];
					return n.result
				}
				var a = t("./zlib/inflate"),
					o = t("./utils/common"),
					s = t("./utils/strings"),
					l = t("./zlib/constants"),
					c = t("./zlib/messages"),
					h = t("./zlib/zstream"),
					u = t("./zlib/gzheader"),
					f = Object.prototype.toString;
				i.prototype.push = function(t, e) {
					var n, i, r, c, h, u, p = this.strm,
						d = this.options.chunkSize,
						m = this.options.dictionary,
						g = !1;
					if(this.ended) return !1;
					i = e === ~~e ? e : !0 === e ? l.Z_FINISH : l.Z_NO_FLUSH, "string" == typeof t ? p.input = s.binstring2buf(t) : "[object ArrayBuffer]" === f.call(t) ? p.input = new Uint8Array(t) : p.input = t, p.next_in = 0, p.avail_in = p.input.length;
					do {
						if(0 === p.avail_out && (p.output = new o.Buf8(d), p.next_out = 0, p.avail_out = d), (n = a.inflate(p, l.Z_NO_FLUSH)) === l.Z_NEED_DICT && m && (u = "string" == typeof m ? s.string2buf(m) : "[object ArrayBuffer]" === f.call(m) ? new Uint8Array(m) : m, n = a.inflateSetDictionary(this.strm, u)), n === l.Z_BUF_ERROR && !0 === g && (n = l.Z_OK, g = !1), n !== l.Z_STREAM_END && n !== l.Z_OK) return this.onEnd(n), this.ended = !0, !1;
						p.next_out && (0 !== p.avail_out && n !== l.Z_STREAM_END && (0 !== p.avail_in || i !== l.Z_FINISH && i !== l.Z_SYNC_FLUSH) || ("string" === this.options.to ? (r = s.utf8border(p.output, p.next_out), c = p.next_out - r, h = s.buf2string(p.output, r), p.next_out = c, p.avail_out = d - c, c && o.arraySet(p.output, p.output, r, c, 0), this.onData(h)) : this.onData(o.shrinkBuf(p.output, p.next_out)))), 0 === p.avail_in && 0 === p.avail_out && (g = !0)
					} while ((p.avail_in > 0 || 0 === p.avail_out) && n !== l.Z_STREAM_END);
					return n === l.Z_STREAM_END && (i = l.Z_FINISH), i === l.Z_FINISH ? (n = a.inflateEnd(this.strm), this.onEnd(n), this.ended = !0, n === l.Z_OK) : i !== l.Z_SYNC_FLUSH || (this.onEnd(l.Z_OK), p.avail_out = 0, !0)
				}, i.prototype.onData = function(t) {
					this.chunks.push(t)
				}, i.prototype.onEnd = function(t) {
					t === l.Z_OK && ("string" === this.options.to ? this.result = this.chunks.join("") : this.result = o.flattenChunks(this.chunks)), this.chunks = [], this.err = t, this.msg = this.strm.msg
				}, n.Inflate = i, n.inflate = r, n.inflateRaw = function(t, e) {
					return e = e || {}, e.raw = !0, r(t, e)
				}, n.ungzip = r
			}, {
				"./utils/common": 62,
				"./utils/strings": 63,
				"./zlib/constants": 65,
				"./zlib/gzheader": 68,
				"./zlib/inflate": 70,
				"./zlib/messages": 72,
				"./zlib/zstream": 74
			}],
			62: [function(t, e, n) {
				"use strict";
				var i = "undefined" != typeof Uint8Array && "undefined" != typeof Uint16Array && "undefined" != typeof Int32Array;
				n.assign = function(t) {
					for(var e = Array.prototype.slice.call(arguments, 1); e.length;) {
						var n = e.shift();
						if(n) {
							if("object" != typeof n) throw new TypeError(n + "must be non-object");
							for(var i in n) n.hasOwnProperty(i) && (t[i] = n[i])
						}
					}
					return t
				}, n.shrinkBuf = function(t, e) {
					return t.length === e ? t : t.subarray ? t.subarray(0, e) : (t.length = e, t)
				};
				var r = {
						arraySet: function(t, e, n, i, r) {
							if(e.subarray && t.subarray) t.set(e.subarray(n, n + i), r);
							else
								for(var a = 0; a < i; a++) t[r + a] = e[n + a]
						},
						flattenChunks: function(t) {
							var e, n, i, r, a, o;
							for(i = 0, e = 0, n = t.length; e < n; e++) i += t[e].length;
							for(o = new Uint8Array(i), r = 0, e = 0, n = t.length; e < n; e++) a = t[e], o.set(a, r), r += a.length;
							return o
						}
					},
					a = {
						arraySet: function(t, e, n, i, r) {
							for(var a = 0; a < i; a++) t[r + a] = e[n + a]
						},
						flattenChunks: function(t) {
							return [].concat.apply([], t)
						}
					};
				n.setTyped = function(t) {
					t ? (n.Buf8 = Uint8Array, n.Buf16 = Uint16Array, n.Buf32 = Int32Array, n.assign(n, r)) : (n.Buf8 = Array, n.Buf16 = Array, n.Buf32 = Array, n.assign(n, a))
				}, n.setTyped(i)
			}, {}],
			63: [function(t, e, n) {
				"use strict";

				function i(t, e) {
					if(e < 65537 && (t.subarray && o || !t.subarray && a)) return String.fromCharCode.apply(null, r.shrinkBuf(t, e));
					for(var n = "", i = 0; i < e; i++) n += String.fromCharCode(t[i]);
					return n
				}
				var r = t("./common"),
					a = !0,
					o = !0;
				try {
					String.fromCharCode.apply(null, [0])
				} catch(t) {
					a = !1
				}
				try {
					String.fromCharCode.apply(null, new Uint8Array(1))
				} catch(t) {
					o = !1
				}
				for(var s = new r.Buf8(256), l = 0; l < 256; l++) s[l] = l >= 252 ? 6 : l >= 248 ? 5 : l >= 240 ? 4 : l >= 224 ? 3 : l >= 192 ? 2 : 1;
				s[254] = s[254] = 1, n.string2buf = function(t) {
					var e, n, i, a, o, s = t.length,
						l = 0;
					for(a = 0; a < s; a++) 55296 == (64512 & (n = t.charCodeAt(a))) && a + 1 < s && 56320 == (64512 & (i = t.charCodeAt(a + 1))) && (n = 65536 + (n - 55296 << 10) + (i - 56320), a++), l += n < 128 ? 1 : n < 2048 ? 2 : n < 65536 ? 3 : 4;
					for(e = new r.Buf8(l), o = 0, a = 0; o < l; a++) 55296 == (64512 & (n = t.charCodeAt(a))) && a + 1 < s && 56320 == (64512 & (i = t.charCodeAt(a + 1))) && (n = 65536 + (n - 55296 << 10) + (i - 56320), a++), n < 128 ? e[o++] = n : n < 2048 ? (e[o++] = 192 | n >>> 6, e[o++] = 128 | 63 & n) : n < 65536 ? (e[o++] = 224 | n >>> 12, e[o++] = 128 | n >>> 6 & 63, e[o++] = 128 | 63 & n) : (e[o++] = 240 | n >>> 18, e[o++] = 128 | n >>> 12 & 63, e[o++] = 128 | n >>> 6 & 63, e[o++] = 128 | 63 & n);
					return e
				}, n.buf2binstring = function(t) {
					return i(t, t.length)
				}, n.binstring2buf = function(t) {
					for(var e = new r.Buf8(t.length), n = 0, i = e.length; n < i; n++) e[n] = t.charCodeAt(n);
					return e
				}, n.buf2string = function(t, e) {
					var n, r, a, o, l = e || t.length,
						c = new Array(2 * l);
					for(r = 0, n = 0; n < l;)
						if((a = t[n++]) < 128) c[r++] = a;
						else if((o = s[a]) > 4) c[r++] = 65533, n += o - 1;
					else {
						for(a &= 2 === o ? 31 : 3 === o ? 15 : 7; o > 1 && n < l;) a = a << 6 | 63 & t[n++], o--;
						o > 1 ? c[r++] = 65533 : a < 65536 ? c[r++] = a : (a -= 65536, c[r++] = 55296 | a >> 10 & 1023, c[r++] = 56320 | 1023 & a)
					}
					return i(c, r)
				}, n.utf8border = function(t, e) {
					var n;
					for((e = e || t.length) > t.length && (e = t.length), n = e - 1; n >= 0 && 128 == (192 & t[n]);) n--;
					return n < 0 ? e : 0 === n ? e : n + s[t[n]] > e ? n : e
				}
			}, {
				"./common": 62
			}],
			64: [function(t, e, n) {
				"use strict";
				e.exports = function(t, e, n, i) {
					for(var r = 65535 & t | 0, a = t >>> 16 & 65535 | 0, o = 0; 0 !== n;) {
						n -= o = n > 2e3 ? 2e3 : n;
						do {
							r = r + e[i++] | 0, a = a + r | 0
						} while (--o);
						r %= 65521, a %= 65521
					}
					return r | a << 16 | 0
				}
			}, {}],
			65: [function(t, e, n) {
				"use strict";
				e.exports = {
					Z_NO_FLUSH: 0,
					Z_PARTIAL_FLUSH: 1,
					Z_SYNC_FLUSH: 2,
					Z_FULL_FLUSH: 3,
					Z_FINISH: 4,
					Z_BLOCK: 5,
					Z_TREES: 6,
					Z_OK: 0,
					Z_STREAM_END: 1,
					Z_NEED_DICT: 2,
					Z_ERRNO: -1,
					Z_STREAM_ERROR: -2,
					Z_DATA_ERROR: -3,
					Z_BUF_ERROR: -5,
					Z_NO_COMPRESSION: 0,
					Z_BEST_SPEED: 1,
					Z_BEST_COMPRESSION: 9,
					Z_DEFAULT_COMPRESSION: -1,
					Z_FILTERED: 1,
					Z_HUFFMAN_ONLY: 2,
					Z_RLE: 3,
					Z_FIXED: 4,
					Z_DEFAULT_STRATEGY: 0,
					Z_BINARY: 0,
					Z_TEXT: 1,
					Z_UNKNOWN: 2,
					Z_DEFLATED: 8
				}
			}, {}],
			66: [function(t, e, n) {
				"use strict";
				var i = function() {
					for(var t, e = [], n = 0; n < 256; n++) {
						t = n;
						for(var i = 0; i < 8; i++) t = 1 & t ? 3988292384 ^ t >>> 1 : t >>> 1;
						e[n] = t
					}
					return e
				}();
				e.exports = function(t, e, n, r) {
					var a = i,
						o = r + n;
					t ^= -1;
					for(var s = r; s < o; s++) t = t >>> 8 ^ a[255 & (t ^ e[s])];
					return -1 ^ t
				}
			}, {}],
			67: [function(t, e, n) {
				"use strict";

				function i(t, e) {
					return t.msg = A[e], e
				}

				function r(t) {
					return(t << 1) - (t > 4 ? 9 : 0)
				}

				function a(t) {
					for(var e = t.length; --e >= 0;) t[e] = 0
				}

				function o(t) {
					var e = t.state,
						n = e.pending;
					n > t.avail_out && (n = t.avail_out), 0 !== n && (S.arraySet(t.output, e.pending_buf, e.pending_out, n, t.next_out), t.next_out += n, e.pending_out += n, t.total_out += n, t.avail_out -= n, e.pending -= n, 0 === e.pending && (e.pending_out = 0))
				}

				function s(t, e) {
					G._tr_flush_block(t, t.block_start >= 0 ? t.block_start : -1, t.strstart - t.block_start, e), t.block_start = t.strstart, o(t.strm)
				}

				function l(t, e) {
					t.pending_buf[t.pending++] = e
				}

				function c(t, e) {
					t.pending_buf[t.pending++] = e >>> 8 & 255, t.pending_buf[t.pending++] = 255 & e
				}

				function h(t, e, n, i) {
					var r = t.avail_in;
					return r > i && (r = i), 0 === r ? 0 : (t.avail_in -= r, S.arraySet(e, t.input, t.next_in, r, n), 1 === t.state.wrap ? t.adler = E(t.adler, e, r, n) : 2 === t.state.wrap && (t.adler = T(t.adler, e, r, n)), t.next_in += r, t.total_in += r, r)
				}

				function u(t, e) {
					var n, i, r = t.max_chain_length,
						a = t.strstart,
						o = t.prev_length,
						s = t.nice_match,
						l = t.strstart > t.w_size - it ? t.strstart - (t.w_size - it) : 0,
						c = t.window,
						h = t.w_mask,
						u = t.prev,
						f = t.strstart + nt,
						p = c[a + o - 1],
						d = c[a + o];
					t.prev_length >= t.good_match && (r >>= 2), s > t.lookahead && (s = t.lookahead);
					do {
						if(n = e, c[n + o] === d && c[n + o - 1] === p && c[n] === c[a] && c[++n] === c[a + 1]) {
							a += 2, n++;
							do {} while (c[++a] === c[++n] && c[++a] === c[++n] && c[++a] === c[++n] && c[++a] === c[++n] && c[++a] === c[++n] && c[++a] === c[++n] && c[++a] === c[++n] && c[++a] === c[++n] && a < f);
							if(i = nt - (f - a), a = f - nt, i > o) {
								if(t.match_start = e, o = i, i >= s) break;
								p = c[a + o - 1], d = c[a + o]
							}
						}
					} while ((e = u[e & h]) > l && 0 != --r);
					return o <= t.lookahead ? o : t.lookahead
				}

				function f(t) {
					var e, n, i, r, a, o = t.w_size;
					do {
						if(r = t.window_size - t.lookahead - t.strstart, t.strstart >= o + (o - it)) {
							S.arraySet(t.window, t.window, o, o, 0), t.match_start -= o, t.strstart -= o, t.block_start -= o, e = n = t.hash_size;
							do {
								i = t.head[--e], t.head[e] = i >= o ? i - o : 0
							} while (--n);
							e = n = o;
							do {
								i = t.prev[--e], t.prev[e] = i >= o ? i - o : 0
							} while (--n);
							r += o
						}
						if(0 === t.strm.avail_in) break;
						if(n = h(t.strm, t.window, t.strstart + t.lookahead, r), t.lookahead += n, t.lookahead + t.insert >= et)
							for(a = t.strstart - t.insert, t.ins_h = t.window[a], t.ins_h = (t.ins_h << t.hash_shift ^ t.window[a + 1]) & t.hash_mask; t.insert && (t.ins_h = (t.ins_h << t.hash_shift ^ t.window[a + et - 1]) & t.hash_mask, t.prev[a & t.w_mask] = t.head[t.ins_h], t.head[t.ins_h] = a, a++, t.insert--, !(t.lookahead + t.insert < et)););
					} while (t.lookahead < it && 0 !== t.strm.avail_in)
				}

				function p(t, e) {
					for(var n, i;;) {
						if(t.lookahead < it) {
							if(f(t), t.lookahead < it && e === L) return ft;
							if(0 === t.lookahead) break
						}
						if(n = 0, t.lookahead >= et && (t.ins_h = (t.ins_h << t.hash_shift ^ t.window[t.strstart + et - 1]) & t.hash_mask, n = t.prev[t.strstart & t.w_mask] = t.head[t.ins_h], t.head[t.ins_h] = t.strstart), 0 !== n && t.strstart - n <= t.w_size - it && (t.match_length = u(t, n)), t.match_length >= et)
							if(i = G._tr_tally(t, t.strstart - t.match_start, t.match_length - et), t.lookahead -= t.match_length, t.match_length <= t.max_lazy_match && t.lookahead >= et) {
								t.match_length--;
								do {
									t.strstart++, t.ins_h = (t.ins_h << t.hash_shift ^ t.window[t.strstart + et - 1]) & t.hash_mask, n = t.prev[t.strstart & t.w_mask] = t.head[t.ins_h], t.head[t.ins_h] = t.strstart
								} while (0 != --t.match_length);
								t.strstart++
							} else t.strstart += t.match_length, t.match_length = 0, t.ins_h = t.window[t.strstart], t.ins_h = (t.ins_h << t.hash_shift ^ t.window[t.strstart + 1]) & t.hash_mask;
						else i = G._tr_tally(t, 0, t.window[t.strstart]), t.lookahead--, t.strstart++;
						if(i && (s(t, !1), 0 === t.strm.avail_out)) return ft
					}
					return t.insert = t.strstart < et - 1 ? t.strstart : et - 1, e === I ? (s(t, !0), 0 === t.strm.avail_out ? dt : mt) : t.last_lit && (s(t, !1), 0 === t.strm.avail_out) ? ft : pt
				}

				function d(t, e) {
					for(var n, i, r;;) {
						if(t.lookahead < it) {
							if(f(t), t.lookahead < it && e === L) return ft;
							if(0 === t.lookahead) break
						}
						if(n = 0, t.lookahead >= et && (t.ins_h = (t.ins_h << t.hash_shift ^ t.window[t.strstart + et - 1]) & t.hash_mask, n = t.prev[t.strstart & t.w_mask] = t.head[t.ins_h], t.head[t.ins_h] = t.strstart), t.prev_length = t.match_length, t.prev_match = t.match_start, t.match_length = et - 1, 0 !== n && t.prev_length < t.max_lazy_match && t.strstart - n <= t.w_size - it && (t.match_length = u(t, n), t.match_length <= 5 && (t.strategy === k || t.match_length === et && t.strstart - t.match_start > 4096) && (t.match_length = et - 1)), t.prev_length >= et && t.match_length <= t.prev_length) {
							r = t.strstart + t.lookahead - et, i = G._tr_tally(t, t.strstart - 1 - t.prev_match, t.prev_length - et), t.lookahead -= t.prev_length - 1, t.prev_length -= 2;
							do {
								++t.strstart <= r && (t.ins_h = (t.ins_h << t.hash_shift ^ t.window[t.strstart + et - 1]) & t.hash_mask, n = t.prev[t.strstart & t.w_mask] = t.head[t.ins_h], t.head[t.ins_h] = t.strstart)
							} while (0 != --t.prev_length);
							if(t.match_available = 0, t.match_length = et - 1, t.strstart++, i && (s(t, !1), 0 === t.strm.avail_out)) return ft
						} else if(t.match_available) {
							if((i = G._tr_tally(t, 0, t.window[t.strstart - 1])) && s(t, !1), t.strstart++, t.lookahead--, 0 === t.strm.avail_out) return ft
						} else t.match_available = 1, t.strstart++, t.lookahead--
					}
					return t.match_available && (i = G._tr_tally(t, 0, t.window[t.strstart - 1]), t.match_available = 0), t.insert = t.strstart < et - 1 ? t.strstart : et - 1, e === I ? (s(t, !0), 0 === t.strm.avail_out ? dt : mt) : t.last_lit && (s(t, !1), 0 === t.strm.avail_out) ? ft : pt
				}

				function m(t, e) {
					for(var n, i, r, a, o = t.window;;) {
						if(t.lookahead <= nt) {
							if(f(t), t.lookahead <= nt && e === L) return ft;
							if(0 === t.lookahead) break
						}
						if(t.match_length = 0, t.lookahead >= et && t.strstart > 0 && (r = t.strstart - 1, (i = o[r]) === o[++r] && i === o[++r] && i === o[++r])) {
							a = t.strstart + nt;
							do {} while (i === o[++r] && i === o[++r] && i === o[++r] && i === o[++r] && i === o[++r] && i === o[++r] && i === o[++r] && i === o[++r] && r < a);
							t.match_length = nt - (a - r), t.match_length > t.lookahead && (t.match_length = t.lookahead)
						}
						if(t.match_length >= et ? (n = G._tr_tally(t, 1, t.match_length - et), t.lookahead -= t.match_length, t.strstart += t.match_length, t.match_length = 0) : (n = G._tr_tally(t, 0, t.window[t.strstart]), t.lookahead--, t.strstart++), n && (s(t, !1), 0 === t.strm.avail_out)) return ft
					}
					return t.insert = 0, e === I ? (s(t, !0), 0 === t.strm.avail_out ? dt : mt) : t.last_lit && (s(t, !1), 0 === t.strm.avail_out) ? ft : pt
				}

				function g(t, e) {
					for(var n;;) {
						if(0 === t.lookahead && (f(t), 0 === t.lookahead)) {
							if(e === L) return ft;
							break
						}
						if(t.match_length = 0, n = G._tr_tally(t, 0, t.window[t.strstart]), t.lookahead--, t.strstart++, n && (s(t, !1), 0 === t.strm.avail_out)) return ft
					}
					return t.insert = 0, e === I ? (s(t, !0), 0 === t.strm.avail_out ? dt : mt) : t.last_lit && (s(t, !1), 0 === t.strm.avail_out) ? ft : pt
				}

				function v(t, e, n, i, r) {
					this.good_length = t, this.max_lazy = e, this.nice_length = n, this.max_chain = i, this.func = r
				}

				function _(t) {
					t.window_size = 2 * t.w_size, a(t.head), t.max_lazy_match = M[t.level].max_lazy, t.good_match = M[t.level].good_length, t.nice_match = M[t.level].nice_length, t.max_chain_length = M[t.level].max_chain, t.strstart = 0, t.block_start = 0, t.lookahead = 0, t.insert = 0, t.match_length = t.prev_length = et - 1, t.match_available = 0, t.ins_h = 0
				}

				function y() {
					this.strm = null, this.status = 0, this.pending_buf = null, this.pending_buf_size = 0, this.pending_out = 0, this.pending = 0, this.wrap = 0, this.gzhead = null, this.gzindex = 0, this.method = X, this.last_flush = -1, this.w_size = 0, this.w_bits = 0, this.w_mask = 0, this.window = null, this.window_size = 0, this.prev = null, this.head = null, this.ins_h = 0, this.hash_size = 0, this.hash_bits = 0, this.hash_mask = 0, this.hash_shift = 0, this.block_start = 0, this.match_length = 0, this.prev_match = 0, this.match_available = 0, this.strstart = 0, this.match_start = 0, this.lookahead = 0, this.prev_length = 0, this.max_chain_length = 0, this.max_lazy_match = 0, this.level = 0, this.strategy = 0, this.good_match = 0, this.nice_match = 0, this.dyn_ltree = new S.Buf16(2 * $), this.dyn_dtree = new S.Buf16(2 * (2 * K + 1)), this.bl_tree = new S.Buf16(2 * (2 * Q + 1)), a(this.dyn_ltree), a(this.dyn_dtree), a(this.bl_tree), this.l_desc = null, this.d_desc = null, this.bl_desc = null, this.bl_count = new S.Buf16(tt + 1), this.heap = new S.Buf16(2 * J + 1), a(this.heap), this.heap_len = 0, this.heap_max = 0, this.depth = new S.Buf16(2 * J + 1), a(this.depth), this.l_buf = 0, this.lit_bufsize = 0, this.last_lit = 0, this.d_buf = 0, this.opt_len = 0, this.static_len = 0, this.matches = 0, this.insert = 0, this.bi_buf = 0, this.bi_valid = 0
				}

				function x(t) {
					var e;
					return t && t.state ? (t.total_in = t.total_out = 0, t.data_type = W, e = t.state, e.pending = 0, e.pending_out = 0, e.wrap < 0 && (e.wrap = -e.wrap), e.status = e.wrap ? at : ht, t.adler = 2 === e.wrap ? 0 : 1, e.last_flush = L, G._tr_init(e), O) : i(t, D)
				}

				function b(t) {
					var e = x(t);
					return e === O && _(t.state), e
				}

				function w(t, e, n, r, a, o) {
					if(!t) return D;
					var s = 1;
					if(e === F && (e = 6), r < 0 ? (s = 0, r = -r) : r > 15 && (s = 2, r -= 16), a < 1 || a > Y || n !== X || r < 8 || r > 15 || e < 0 || e > 9 || o < 0 || o > j) return i(t, D);
					8 === r && (r = 9);
					var l = new y;
					return t.state = l, l.strm = t, l.wrap = s, l.gzhead = null, l.w_bits = r, l.w_size = 1 << l.w_bits, l.w_mask = l.w_size - 1, l.hash_bits = a + 7, l.hash_size = 1 << l.hash_bits, l.hash_mask = l.hash_size - 1, l.hash_shift = ~~((l.hash_bits + et - 1) / et), l.window = new S.Buf8(2 * l.w_size), l.head = new S.Buf16(l.hash_size), l.prev = new S.Buf16(l.w_size), l.lit_bufsize = 1 << a + 6, l.pending_buf_size = 4 * l.lit_bufsize, l.pending_buf = new S.Buf8(l.pending_buf_size), l.d_buf = 1 * l.lit_bufsize, l.l_buf = 3 * l.lit_bufsize, l.level = e, l.strategy = o, l.method = n, b(t)
				}
				var M, S = t("../utils/common"),
					G = t("./trees"),
					E = t("./adler32"),
					T = t("./crc32"),
					A = t("./messages"),
					L = 0,
					C = 1,
					P = 3,
					I = 4,
					R = 5,
					O = 0,
					N = 1,
					D = -2,
					z = -3,
					U = -5,
					F = -1,
					k = 1,
					B = 2,
					V = 3,
					j = 4,
					H = 0,
					W = 2,
					X = 8,
					Y = 9,
					q = 15,
					Z = 8,
					J = 286,
					K = 30,
					Q = 19,
					$ = 2 * J + 1,
					tt = 15,
					et = 3,
					nt = 258,
					it = nt + et + 1,
					rt = 32,
					at = 42,
					ot = 69,
					st = 73,
					lt = 91,
					ct = 103,
					ht = 113,
					ut = 666,
					ft = 1,
					pt = 2,
					dt = 3,
					mt = 4,
					gt = 3;
				M = [new v(0, 0, 0, 0, function(t, e) {
					var n = 65535;
					for(n > t.pending_buf_size - 5 && (n = t.pending_buf_size - 5);;) {
						if(t.lookahead <= 1) {
							if(f(t), 0 === t.lookahead && e === L) return ft;
							if(0 === t.lookahead) break
						}
						t.strstart += t.lookahead, t.lookahead = 0;
						var i = t.block_start + n;
						if((0 === t.strstart || t.strstart >= i) && (t.lookahead = t.strstart - i, t.strstart = i, s(t, !1), 0 === t.strm.avail_out)) return ft;
						if(t.strstart - t.block_start >= t.w_size - it && (s(t, !1), 0 === t.strm.avail_out)) return ft
					}
					return t.insert = 0, e === I ? (s(t, !0), 0 === t.strm.avail_out ? dt : mt) : (t.strstart > t.block_start && (s(t, !1), t.strm.avail_out), ft)
				}), new v(4, 4, 8, 4, p), new v(4, 5, 16, 8, p), new v(4, 6, 32, 32, p), new v(4, 4, 16, 16, d), new v(8, 16, 32, 32, d), new v(8, 16, 128, 128, d), new v(8, 32, 128, 256, d), new v(32, 128, 258, 1024, d), new v(32, 258, 258, 4096, d)], n.deflateInit = function(t, e) {
					return w(t, e, X, q, Z, H)
				}, n.deflateInit2 = w, n.deflateReset = b, n.deflateResetKeep = x, n.deflateSetHeader = function(t, e) {
					return t && t.state ? 2 !== t.state.wrap ? D : (t.state.gzhead = e, O) : D
				}, n.deflate = function(t, e) {
					var n, s, h, u;
					if(!t || !t.state || e > R || e < 0) return t ? i(t, D) : D;
					if(s = t.state, !t.output || !t.input && 0 !== t.avail_in || s.status === ut && e !== I) return i(t, 0 === t.avail_out ? U : D);
					if(s.strm = t, n = s.last_flush, s.last_flush = e, s.status === at)
						if(2 === s.wrap) t.adler = 0, l(s, 31), l(s, 139), l(s, 8), s.gzhead ? (l(s, (s.gzhead.text ? 1 : 0) + (s.gzhead.hcrc ? 2 : 0) + (s.gzhead.extra ? 4 : 0) + (s.gzhead.name ? 8 : 0) + (s.gzhead.comment ? 16 : 0)), l(s, 255 & s.gzhead.time), l(s, s.gzhead.time >> 8 & 255), l(s, s.gzhead.time >> 16 & 255), l(s, s.gzhead.time >> 24 & 255), l(s, 9 === s.level ? 2 : s.strategy >= B || s.level < 2 ? 4 : 0), l(s, 255 & s.gzhead.os), s.gzhead.extra && s.gzhead.extra.length && (l(s, 255 & s.gzhead.extra.length), l(s, s.gzhead.extra.length >> 8 & 255)), s.gzhead.hcrc && (t.adler = T(t.adler, s.pending_buf, s.pending, 0)), s.gzindex = 0, s.status = ot) : (l(s, 0), l(s, 0), l(s, 0), l(s, 0), l(s, 0), l(s, 9 === s.level ? 2 : s.strategy >= B || s.level < 2 ? 4 : 0), l(s, gt), s.status = ht);
						else {
							var f = X + (s.w_bits - 8 << 4) << 8;
							f |= (s.strategy >= B || s.level < 2 ? 0 : s.level < 6 ? 1 : 6 === s.level ? 2 : 3) << 6, 0 !== s.strstart && (f |= rt), f += 31 - f % 31, s.status = ht, c(s, f), 0 !== s.strstart && (c(s, t.adler >>> 16), c(s, 65535 & t.adler)), t.adler = 1
						}
					if(s.status === ot)
						if(s.gzhead.extra) {
							for(h = s.pending; s.gzindex < (65535 & s.gzhead.extra.length) && (s.pending !== s.pending_buf_size || (s.gzhead.hcrc && s.pending > h && (t.adler = T(t.adler, s.pending_buf, s.pending - h, h)), o(t), h = s.pending, s.pending !== s.pending_buf_size));) l(s, 255 & s.gzhead.extra[s.gzindex]), s.gzindex++;
							s.gzhead.hcrc && s.pending > h && (t.adler = T(t.adler, s.pending_buf, s.pending - h, h)), s.gzindex === s.gzhead.extra.length && (s.gzindex = 0, s.status = st)
						} else s.status = st;
					if(s.status === st)
						if(s.gzhead.name) {
							h = s.pending;
							do {
								if(s.pending === s.pending_buf_size && (s.gzhead.hcrc && s.pending > h && (t.adler = T(t.adler, s.pending_buf, s.pending - h, h)), o(t), h = s.pending, s.pending === s.pending_buf_size)) {
									u = 1;
									break
								}
								u = s.gzindex < s.gzhead.name.length ? 255 & s.gzhead.name.charCodeAt(s.gzindex++) : 0, l(s, u)
							} while (0 !== u);
							s.gzhead.hcrc && s.pending > h && (t.adler = T(t.adler, s.pending_buf, s.pending - h, h)), 0 === u && (s.gzindex = 0, s.status = lt)
						} else s.status = lt;
					if(s.status === lt)
						if(s.gzhead.comment) {
							h = s.pending;
							do {
								if(s.pending === s.pending_buf_size && (s.gzhead.hcrc && s.pending > h && (t.adler = T(t.adler, s.pending_buf, s.pending - h, h)), o(t), h = s.pending, s.pending === s.pending_buf_size)) {
									u = 1;
									break
								}
								u = s.gzindex < s.gzhead.comment.length ? 255 & s.gzhead.comment.charCodeAt(s.gzindex++) : 0, l(s, u)
							} while (0 !== u);
							s.gzhead.hcrc && s.pending > h && (t.adler = T(t.adler, s.pending_buf, s.pending - h, h)), 0 === u && (s.status = ct)
						} else s.status = ct;
					if(s.status === ct && (s.gzhead.hcrc ? (s.pending + 2 > s.pending_buf_size && o(t), s.pending + 2 <= s.pending_buf_size && (l(s, 255 & t.adler), l(s, t.adler >> 8 & 255), t.adler = 0, s.status = ht)) : s.status = ht), 0 !== s.pending) {
						if(o(t), 0 === t.avail_out) return s.last_flush = -1, O
					} else if(0 === t.avail_in && r(e) <= r(n) && e !== I) return i(t, U);
					if(s.status === ut && 0 !== t.avail_in) return i(t, U);
					if(0 !== t.avail_in || 0 !== s.lookahead || e !== L && s.status !== ut) {
						var p = s.strategy === B ? g(s, e) : s.strategy === V ? m(s, e) : M[s.level].func(s, e);
						if(p !== dt && p !== mt || (s.status = ut), p === ft || p === dt) return 0 === t.avail_out && (s.last_flush = -1), O;
						if(p === pt && (e === C ? G._tr_align(s) : e !== R && (G._tr_stored_block(s, 0, 0, !1), e === P && (a(s.head), 0 === s.lookahead && (s.strstart = 0, s.block_start = 0, s.insert = 0))), o(t), 0 === t.avail_out)) return s.last_flush = -1, O
					}
					return e !== I ? O : s.wrap <= 0 ? N : (2 === s.wrap ? (l(s, 255 & t.adler), l(s, t.adler >> 8 & 255), l(s, t.adler >> 16 & 255), l(s, t.adler >> 24 & 255), l(s, 255 & t.total_in), l(s, t.total_in >> 8 & 255), l(s, t.total_in >> 16 & 255), l(s, t.total_in >> 24 & 255)) : (c(s, t.adler >>> 16), c(s, 65535 & t.adler)), o(t), s.wrap > 0 && (s.wrap = -s.wrap), 0 !== s.pending ? O : N)
				}, n.deflateEnd = function(t) {
					var e;
					return t && t.state ? (e = t.state.status, e !== at && e !== ot && e !== st && e !== lt && e !== ct && e !== ht && e !== ut ? i(t, D) : (t.state = null, e === ht ? i(t, z) : O)) : D
				}, n.deflateSetDictionary = function(t, e) {
					var n, i, r, o, s, l, c, h, u = e.length;
					if(!t || !t.state) return D;
					if(n = t.state, 2 === (o = n.wrap) || 1 === o && n.status !== at || n.lookahead) return D;
					for(1 === o && (t.adler = E(t.adler, e, u, 0)), n.wrap = 0, u >= n.w_size && (0 === o && (a(n.head), n.strstart = 0, n.block_start = 0, n.insert = 0), h = new S.Buf8(n.w_size), S.arraySet(h, e, u - n.w_size, n.w_size, 0), e = h, u = n.w_size), s = t.avail_in, l = t.next_in, c = t.input, t.avail_in = u, t.next_in = 0, t.input = e, f(n); n.lookahead >= et;) {
						i = n.strstart, r = n.lookahead - (et - 1);
						do {
							n.ins_h = (n.ins_h << n.hash_shift ^ n.window[i + et - 1]) & n.hash_mask, n.prev[i & n.w_mask] = n.head[n.ins_h], n.head[n.ins_h] = i, i++
						} while (--r);
						n.strstart = i, n.lookahead = et - 1, f(n)
					}
					return n.strstart += n.lookahead, n.block_start = n.strstart, n.insert = n.lookahead, n.lookahead = 0, n.match_length = n.prev_length = et - 1, n.match_available = 0, t.next_in = l, t.input = c, t.avail_in = s, n.wrap = o, O
				}, n.deflateInfo = "pako deflate (from Nodeca project)"
			}, {
				"../utils/common": 62,
				"./adler32": 64,
				"./crc32": 66,
				"./messages": 72,
				"./trees": 73
			}],
			68: [function(t, e, n) {
				"use strict";
				e.exports = function() {
					this.text = 0, this.time = 0, this.xflags = 0, this.os = 0, this.extra = null, this.extra_len = 0, this.name = "", this.comment = "", this.hcrc = 0, this.done = !1
				}
			}, {}],
			69: [function(t, e, n) {
				"use strict";
				e.exports = function(t, e) {
					var n, i, r, a, o, s, l, c, h, u, f, p, d, m, g, v, _, y, x, b, w, M, S, G, E;
					n = t.state, i = t.next_in, G = t.input, r = i + (t.avail_in - 5), a = t.next_out, E = t.output, o = a - (e - t.avail_out), s = a + (t.avail_out - 257), l = n.dmax, c = n.wsize, h = n.whave, u = n.wnext, f = n.window, p = n.hold, d = n.bits, m = n.lencode, g = n.distcode, v = (1 << n.lenbits) - 1, _ = (1 << n.distbits) - 1;
					t: do {
						d < 15 && (p += G[i++] << d, d += 8, p += G[i++] << d, d += 8), y = m[p & v];
						e: for(;;) {
							if(x = y >>> 24, p >>>= x, d -= x, 0 === (x = y >>> 16 & 255)) E[a++] = 65535 & y;
							else {
								if(!(16 & x)) {
									if(0 == (64 & x)) {
										y = m[(65535 & y) + (p & (1 << x) - 1)];
										continue e
									}
									if(32 & x) {
										n.mode = 12;
										break t
									}
									t.msg = "invalid literal/length code", n.mode = 30;
									break t
								}
								b = 65535 & y, (x &= 15) && (d < x && (p += G[i++] << d, d += 8), b += p & (1 << x) - 1, p >>>= x, d -= x), d < 15 && (p += G[i++] << d, d += 8, p += G[i++] << d, d += 8), y = g[p & _];
								n: for(;;) {
									if(x = y >>> 24, p >>>= x, d -= x, !(16 & (x = y >>> 16 & 255))) {
										if(0 == (64 & x)) {
											y = g[(65535 & y) + (p & (1 << x) - 1)];
											continue n
										}
										t.msg = "invalid distance code", n.mode = 30;
										break t
									}
									if(w = 65535 & y, x &= 15, d < x && (p += G[i++] << d, (d += 8) < x && (p += G[i++] << d, d += 8)), (w += p & (1 << x) - 1) > l) {
										t.msg = "invalid distance too far back", n.mode = 30;
										break t
									}
									if(p >>>= x, d -= x, x = a - o, w > x) {
										if((x = w - x) > h && n.sane) {
											t.msg = "invalid distance too far back", n.mode = 30;
											break t
										}
										if(M = 0, S = f, 0 === u) {
											if(M += c - x, x < b) {
												b -= x;
												do {
													E[a++] = f[M++]
												} while (--x);
												M = a - w, S = E
											}
										} else if(u < x) {
											if(M += c + u - x, (x -= u) < b) {
												b -= x;
												do {
													E[a++] = f[M++]
												} while (--x);
												if(M = 0, u < b) {
													b -= x = u;
													do {
														E[a++] = f[M++]
													} while (--x);
													M = a - w, S = E
												}
											}
										} else if(M += u - x, x < b) {
											b -= x;
											do {
												E[a++] = f[M++]
											} while (--x);
											M = a - w, S = E
										}
										for(; b > 2;) E[a++] = S[M++], E[a++] = S[M++], E[a++] = S[M++], b -= 3;
										b && (E[a++] = S[M++], b > 1 && (E[a++] = S[M++]))
									} else {
										M = a - w;
										do {
											E[a++] = E[M++], E[a++] = E[M++], E[a++] = E[M++], b -= 3
										} while (b > 2);
										b && (E[a++] = E[M++], b > 1 && (E[a++] = E[M++]))
									}
									break
								}
							}
							break
						}
					} while (i < r && a < s);
					i -= b = d >> 3, p &= (1 << (d -= b << 3)) - 1, t.next_in = i, t.next_out = a, t.avail_in = i < r ? r - i + 5 : 5 - (i - r), t.avail_out = a < s ? s - a + 257 : 257 - (a - s), n.hold = p, n.bits = d
				}
			}, {}],
			70: [function(t, e, n) {
				"use strict";

				function i(t) {
					return(t >>> 24 & 255) + (t >>> 8 & 65280) + ((65280 & t) << 8) + ((255 & t) << 24)
				}

				function r() {
					this.mode = 0, this.last = !1, this.wrap = 0, this.havedict = !1, this.flags = 0, this.dmax = 0, this.check = 0, this.total = 0, this.head = null, this.wbits = 0, this.wsize = 0, this.whave = 0, this.wnext = 0, this.window = null, this.hold = 0, this.bits = 0, this.length = 0, this.offset = 0, this.extra = 0, this.lencode = null, this.distcode = null, this.lenbits = 0, this.distbits = 0, this.ncode = 0, this.nlen = 0, this.ndist = 0, this.have = 0, this.next = null, this.lens = new p.Buf16(320), this.work = new p.Buf16(288), this.lendyn = null, this.distdyn = null, this.sane = 0, this.back = 0, this.was = 0
				}

				function a(t) {
					var e;
					return t && t.state ? (e = t.state, t.total_in = t.total_out = e.total = 0, t.msg = "", e.wrap && (t.adler = 1 & e.wrap), e.mode = I, e.last = 0, e.havedict = 0, e.dmax = 32768, e.head = null, e.hold = 0, e.bits = 0, e.lencode = e.lendyn = new p.Buf32(ht), e.distcode = e.distdyn = new p.Buf32(ut), e.sane = 1, e.back = -1, S) : T
				}

				function o(t) {
					var e;
					return t && t.state ? (e = t.state, e.wsize = 0, e.whave = 0, e.wnext = 0, a(t)) : T
				}

				function s(t, e) {
					var n, i;
					return t && t.state ? (i = t.state, e < 0 ? (n = 0, e = -e) : (n = 1 + (e >> 4), e < 48 && (e &= 15)), e && (e < 8 || e > 15) ? T : (null !== i.window && i.wbits !== e && (i.window = null), i.wrap = n, i.wbits = e, o(t))) : T
				}

				function l(t, e) {
					var n, i;
					return t ? (i = new r, t.state = i, i.window = null, (n = s(t, e)) !== S && (t.state = null), n) : T
				}

				function c(t) {
					if(pt) {
						var e;
						for(u = new p.Buf32(512), f = new p.Buf32(32), e = 0; e < 144;) t.lens[e++] = 8;
						for(; e < 256;) t.lens[e++] = 9;
						for(; e < 280;) t.lens[e++] = 7;
						for(; e < 288;) t.lens[e++] = 8;
						for(v(y, t.lens, 0, 288, u, 0, t.work, {
								bits: 9
							}), e = 0; e < 32;) t.lens[e++] = 5;
						v(x, t.lens, 0, 32, f, 0, t.work, {
							bits: 5
						}), pt = !1
					}
					t.lencode = u, t.lenbits = 9, t.distcode = f, t.distbits = 5
				}

				function h(t, e, n, i) {
					var r, a = t.state;
					return null === a.window && (a.wsize = 1 << a.wbits, a.wnext = 0, a.whave = 0, a.window = new p.Buf8(a.wsize)), i >= a.wsize ? (p.arraySet(a.window, e, n - a.wsize, a.wsize, 0), a.wnext = 0, a.whave = a.wsize) : ((r = a.wsize - a.wnext) > i && (r = i), p.arraySet(a.window, e, n - i, r, a.wnext), i -= r, i ? (p.arraySet(a.window, e, n - i, i, 0), a.wnext = i, a.whave = a.wsize) : (a.wnext += r, a.wnext === a.wsize && (a.wnext = 0), a.whave < a.wsize && (a.whave += r))), 0
				}
				var u, f, p = t("../utils/common"),
					d = t("./adler32"),
					m = t("./crc32"),
					g = t("./inffast"),
					v = t("./inftrees"),
					_ = 0,
					y = 1,
					x = 2,
					b = 4,
					w = 5,
					M = 6,
					S = 0,
					G = 1,
					E = 2,
					T = -2,
					A = -3,
					L = -4,
					C = -5,
					P = 8,
					I = 1,
					R = 2,
					O = 3,
					N = 4,
					D = 5,
					z = 6,
					U = 7,
					F = 8,
					k = 9,
					B = 10,
					V = 11,
					j = 12,
					H = 13,
					W = 14,
					X = 15,
					Y = 16,
					q = 17,
					Z = 18,
					J = 19,
					K = 20,
					Q = 21,
					$ = 22,
					tt = 23,
					et = 24,
					nt = 25,
					it = 26,
					rt = 27,
					at = 28,
					ot = 29,
					st = 30,
					lt = 31,
					ct = 32,
					ht = 852,
					ut = 592,
					ft = 15,
					pt = !0;
				n.inflateReset = o, n.inflateReset2 = s, n.inflateResetKeep = a, n.inflateInit = function(t) {
					return l(t, ft)
				}, n.inflateInit2 = l, n.inflate = function(t, e) {
					var n, r, a, o, s, l, u, f, ht, ut, ft, pt, dt, mt, gt, vt, _t, yt, xt, bt, wt, Mt, St, Gt, Et = 0,
						Tt = new p.Buf8(4),
						At = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];
					if(!t || !t.state || !t.output || !t.input && 0 !== t.avail_in) return T;
					(n = t.state).mode === j && (n.mode = H), s = t.next_out, a = t.output, u = t.avail_out, o = t.next_in, r = t.input, l = t.avail_in, f = n.hold, ht = n.bits, ut = l, ft = u, Mt = S;
					t: for(;;) switch(n.mode) {
						case I:
							if(0 === n.wrap) {
								n.mode = H;
								break
							}
							for(; ht < 16;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							if(2 & n.wrap && 35615 === f) {
								n.check = 0, Tt[0] = 255 & f, Tt[1] = f >>> 8 & 255, n.check = m(n.check, Tt, 2, 0), f = 0, ht = 0, n.mode = R;
								break
							}
							if(n.flags = 0, n.head && (n.head.done = !1), !(1 & n.wrap) || (((255 & f) << 8) + (f >> 8)) % 31) {
								t.msg = "incorrect header check", n.mode = st;
								break
							}
							if((15 & f) !== P) {
								t.msg = "unknown compression method", n.mode = st;
								break
							}
							if(f >>>= 4, ht -= 4, wt = 8 + (15 & f), 0 === n.wbits) n.wbits = wt;
							else if(wt > n.wbits) {
								t.msg = "invalid window size", n.mode = st;
								break
							}
							n.dmax = 1 << wt, t.adler = n.check = 1, n.mode = 512 & f ? B : j, f = 0, ht = 0;
							break;
						case R:
							for(; ht < 16;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							if(n.flags = f, (255 & n.flags) !== P) {
								t.msg = "unknown compression method", n.mode = st;
								break
							}
							if(57344 & n.flags) {
								t.msg = "unknown header flags set", n.mode = st;
								break
							}
							n.head && (n.head.text = f >> 8 & 1), 512 & n.flags && (Tt[0] = 255 & f, Tt[1] = f >>> 8 & 255, n.check = m(n.check, Tt, 2, 0)), f = 0, ht = 0, n.mode = O;
						case O:
							for(; ht < 32;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							n.head && (n.head.time = f), 512 & n.flags && (Tt[0] = 255 & f, Tt[1] = f >>> 8 & 255, Tt[2] = f >>> 16 & 255, Tt[3] = f >>> 24 & 255, n.check = m(n.check, Tt, 4, 0)), f = 0, ht = 0, n.mode = N;
						case N:
							for(; ht < 16;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							n.head && (n.head.xflags = 255 & f, n.head.os = f >> 8), 512 & n.flags && (Tt[0] = 255 & f, Tt[1] = f >>> 8 & 255, n.check = m(n.check, Tt, 2, 0)), f = 0, ht = 0, n.mode = D;
						case D:
							if(1024 & n.flags) {
								for(; ht < 16;) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								n.length = f, n.head && (n.head.extra_len = f), 512 & n.flags && (Tt[0] = 255 & f, Tt[1] = f >>> 8 & 255, n.check = m(n.check, Tt, 2, 0)), f = 0, ht = 0
							} else n.head && (n.head.extra = null);
							n.mode = z;
						case z:
							if(1024 & n.flags && ((pt = n.length) > l && (pt = l), pt && (n.head && (wt = n.head.extra_len - n.length, n.head.extra || (n.head.extra = new Array(n.head.extra_len)), p.arraySet(n.head.extra, r, o, pt, wt)), 512 & n.flags && (n.check = m(n.check, r, pt, o)), l -= pt, o += pt, n.length -= pt), n.length)) break t;
							n.length = 0, n.mode = U;
						case U:
							if(2048 & n.flags) {
								if(0 === l) break t;
								pt = 0;
								do {
									wt = r[o + pt++], n.head && wt && n.length < 65536 && (n.head.name += String.fromCharCode(wt))
								} while (wt && pt < l);
								if(512 & n.flags && (n.check = m(n.check, r, pt, o)), l -= pt, o += pt, wt) break t
							} else n.head && (n.head.name = null);
							n.length = 0, n.mode = F;
						case F:
							if(4096 & n.flags) {
								if(0 === l) break t;
								pt = 0;
								do {
									wt = r[o + pt++], n.head && wt && n.length < 65536 && (n.head.comment += String.fromCharCode(wt))
								} while (wt && pt < l);
								if(512 & n.flags && (n.check = m(n.check, r, pt, o)), l -= pt, o += pt, wt) break t
							} else n.head && (n.head.comment = null);
							n.mode = k;
						case k:
							if(512 & n.flags) {
								for(; ht < 16;) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								if(f !== (65535 & n.check)) {
									t.msg = "header crc mismatch", n.mode = st;
									break
								}
								f = 0, ht = 0
							}
							n.head && (n.head.hcrc = n.flags >> 9 & 1, n.head.done = !0), t.adler = n.check = 0, n.mode = j;
							break;
						case B:
							for(; ht < 32;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							t.adler = n.check = i(f), f = 0, ht = 0, n.mode = V;
						case V:
							if(0 === n.havedict) return t.next_out = s, t.avail_out = u, t.next_in = o, t.avail_in = l, n.hold = f, n.bits = ht, E;
							t.adler = n.check = 1, n.mode = j;
						case j:
							if(e === w || e === M) break t;
						case H:
							if(n.last) {
								f >>>= 7 & ht, ht -= 7 & ht, n.mode = rt;
								break
							}
							for(; ht < 3;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							switch(n.last = 1 & f, f >>>= 1, ht -= 1, 3 & f) {
								case 0:
									n.mode = W;
									break;
								case 1:
									if(c(n), n.mode = K, e === M) {
										f >>>= 2, ht -= 2;
										break t
									}
									break;
								case 2:
									n.mode = q;
									break;
								case 3:
									t.msg = "invalid block type", n.mode = st
							}
							f >>>= 2, ht -= 2;
							break;
						case W:
							for(f >>>= 7 & ht, ht -= 7 & ht; ht < 32;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							if((65535 & f) != (f >>> 16 ^ 65535)) {
								t.msg = "invalid stored block lengths", n.mode = st;
								break
							}
							if(n.length = 65535 & f, f = 0, ht = 0, n.mode = X, e === M) break t;
						case X:
							n.mode = Y;
						case Y:
							if(pt = n.length) {
								if(pt > l && (pt = l), pt > u && (pt = u), 0 === pt) break t;
								p.arraySet(a, r, o, pt, s), l -= pt, o += pt, u -= pt, s += pt, n.length -= pt;
								break
							}
							n.mode = j;
							break;
						case q:
							for(; ht < 14;) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							if(n.nlen = 257 + (31 & f), f >>>= 5, ht -= 5, n.ndist = 1 + (31 & f), f >>>= 5, ht -= 5, n.ncode = 4 + (15 & f), f >>>= 4, ht -= 4, n.nlen > 286 || n.ndist > 30) {
								t.msg = "too many length or distance symbols", n.mode = st;
								break
							}
							n.have = 0, n.mode = Z;
						case Z:
							for(; n.have < n.ncode;) {
								for(; ht < 3;) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								n.lens[At[n.have++]] = 7 & f, f >>>= 3, ht -= 3
							}
							for(; n.have < 19;) n.lens[At[n.have++]] = 0;
							if(n.lencode = n.lendyn, n.lenbits = 7, St = {
									bits: n.lenbits
								}, Mt = v(_, n.lens, 0, 19, n.lencode, 0, n.work, St), n.lenbits = St.bits, Mt) {
								t.msg = "invalid code lengths set", n.mode = st;
								break
							}
							n.have = 0, n.mode = J;
						case J:
							for(; n.have < n.nlen + n.ndist;) {
								for(; Et = n.lencode[f & (1 << n.lenbits) - 1], gt = Et >>> 24, vt = Et >>> 16 & 255, _t = 65535 & Et, !(gt <= ht);) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								if(_t < 16) f >>>= gt, ht -= gt, n.lens[n.have++] = _t;
								else {
									if(16 === _t) {
										for(Gt = gt + 2; ht < Gt;) {
											if(0 === l) break t;
											l--, f += r[o++] << ht, ht += 8
										}
										if(f >>>= gt, ht -= gt, 0 === n.have) {
											t.msg = "invalid bit length repeat", n.mode = st;
											break
										}
										wt = n.lens[n.have - 1], pt = 3 + (3 & f), f >>>= 2, ht -= 2
									} else if(17 === _t) {
										for(Gt = gt + 3; ht < Gt;) {
											if(0 === l) break t;
											l--, f += r[o++] << ht, ht += 8
										}
										ht -= gt, wt = 0, pt = 3 + (7 & (f >>>= gt)), f >>>= 3, ht -= 3
									} else {
										for(Gt = gt + 7; ht < Gt;) {
											if(0 === l) break t;
											l--, f += r[o++] << ht, ht += 8
										}
										ht -= gt, wt = 0, pt = 11 + (127 & (f >>>= gt)), f >>>= 7, ht -= 7
									}
									if(n.have + pt > n.nlen + n.ndist) {
										t.msg = "invalid bit length repeat", n.mode = st;
										break
									}
									for(; pt--;) n.lens[n.have++] = wt
								}
							}
							if(n.mode === st) break;
							if(0 === n.lens[256]) {
								t.msg = "invalid code -- missing end-of-block", n.mode = st;
								break
							}
							if(n.lenbits = 9, St = {
									bits: n.lenbits
								}, Mt = v(y, n.lens, 0, n.nlen, n.lencode, 0, n.work, St), n.lenbits = St.bits, Mt) {
								t.msg = "invalid literal/lengths set", n.mode = st;
								break
							}
							if(n.distbits = 6, n.distcode = n.distdyn, St = {
									bits: n.distbits
								}, Mt = v(x, n.lens, n.nlen, n.ndist, n.distcode, 0, n.work, St), n.distbits = St.bits, Mt) {
								t.msg = "invalid distances set", n.mode = st;
								break
							}
							if(n.mode = K, e === M) break t;
						case K:
							n.mode = Q;
						case Q:
							if(l >= 6 && u >= 258) {
								t.next_out = s, t.avail_out = u, t.next_in = o, t.avail_in = l, n.hold = f, n.bits = ht, g(t, ft), s = t.next_out, a = t.output, u = t.avail_out, o = t.next_in, r = t.input, l = t.avail_in, f = n.hold, ht = n.bits, n.mode === j && (n.back = -1);
								break
							}
							for(n.back = 0; Et = n.lencode[f & (1 << n.lenbits) - 1], gt = Et >>> 24, vt = Et >>> 16 & 255, _t = 65535 & Et, !(gt <= ht);) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							if(vt && 0 == (240 & vt)) {
								for(yt = gt, xt = vt, bt = _t; Et = n.lencode[bt + ((f & (1 << yt + xt) - 1) >> yt)], gt = Et >>> 24, vt = Et >>> 16 & 255, _t = 65535 & Et, !(yt + gt <= ht);) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								f >>>= yt, ht -= yt, n.back += yt
							}
							if(f >>>= gt, ht -= gt, n.back += gt, n.length = _t, 0 === vt) {
								n.mode = it;
								break
							}
							if(32 & vt) {
								n.back = -1, n.mode = j;
								break
							}
							if(64 & vt) {
								t.msg = "invalid literal/length code", n.mode = st;
								break
							}
							n.extra = 15 & vt, n.mode = $;
						case $:
							if(n.extra) {
								for(Gt = n.extra; ht < Gt;) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								n.length += f & (1 << n.extra) - 1, f >>>= n.extra, ht -= n.extra, n.back += n.extra
							}
							n.was = n.length, n.mode = tt;
						case tt:
							for(; Et = n.distcode[f & (1 << n.distbits) - 1], gt = Et >>> 24, vt = Et >>> 16 & 255, _t = 65535 & Et, !(gt <= ht);) {
								if(0 === l) break t;
								l--, f += r[o++] << ht, ht += 8
							}
							if(0 == (240 & vt)) {
								for(yt = gt, xt = vt, bt = _t; Et = n.distcode[bt + ((f & (1 << yt + xt) - 1) >> yt)], gt = Et >>> 24, vt = Et >>> 16 & 255, _t = 65535 & Et, !(yt + gt <= ht);) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								f >>>= yt, ht -= yt, n.back += yt
							}
							if(f >>>= gt, ht -= gt, n.back += gt, 64 & vt) {
								t.msg = "invalid distance code", n.mode = st;
								break
							}
							n.offset = _t, n.extra = 15 & vt, n.mode = et;
						case et:
							if(n.extra) {
								for(Gt = n.extra; ht < Gt;) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								n.offset += f & (1 << n.extra) - 1, f >>>= n.extra, ht -= n.extra, n.back += n.extra
							}
							if(n.offset > n.dmax) {
								t.msg = "invalid distance too far back", n.mode = st;
								break
							}
							n.mode = nt;
						case nt:
							if(0 === u) break t;
							if(pt = ft - u, n.offset > pt) {
								if((pt = n.offset - pt) > n.whave && n.sane) {
									t.msg = "invalid distance too far back", n.mode = st;
									break
								}
								pt > n.wnext ? (pt -= n.wnext, dt = n.wsize - pt) : dt = n.wnext - pt, pt > n.length && (pt = n.length), mt = n.window
							} else mt = a, dt = s - n.offset, pt = n.length;
							pt > u && (pt = u), u -= pt, n.length -= pt;
							do {
								a[s++] = mt[dt++]
							} while (--pt);
							0 === n.length && (n.mode = Q);
							break;
						case it:
							if(0 === u) break t;
							a[s++] = n.length, u--, n.mode = Q;
							break;
						case rt:
							if(n.wrap) {
								for(; ht < 32;) {
									if(0 === l) break t;
									l--, f |= r[o++] << ht, ht += 8
								}
								if(ft -= u, t.total_out += ft, n.total += ft, ft && (t.adler = n.check = n.flags ? m(n.check, a, ft, s - ft) : d(n.check, a, ft, s - ft)), ft = u, (n.flags ? f : i(f)) !== n.check) {
									t.msg = "incorrect data check", n.mode = st;
									break
								}
								f = 0, ht = 0
							}
							n.mode = at;
						case at:
							if(n.wrap && n.flags) {
								for(; ht < 32;) {
									if(0 === l) break t;
									l--, f += r[o++] << ht, ht += 8
								}
								if(f !== (4294967295 & n.total)) {
									t.msg = "incorrect length check", n.mode = st;
									break
								}
								f = 0, ht = 0
							}
							n.mode = ot;
						case ot:
							Mt = G;
							break t;
						case st:
							Mt = A;
							break t;
						case lt:
							return L;
						case ct:
						default:
							return T
					}
					return t.next_out = s, t.avail_out = u, t.next_in = o, t.avail_in = l, n.hold = f, n.bits = ht, (n.wsize || ft !== t.avail_out && n.mode < st && (n.mode < rt || e !== b)) && h(t, t.output, t.next_out, ft - t.avail_out) ? (n.mode = lt, L) : (ut -= t.avail_in, ft -= t.avail_out, t.total_in += ut, t.total_out += ft, n.total += ft, n.wrap && ft && (t.adler = n.check = n.flags ? m(n.check, a, ft, t.next_out - ft) : d(n.check, a, ft, t.next_out - ft)), t.data_type = n.bits + (n.last ? 64 : 0) + (n.mode === j ? 128 : 0) + (n.mode === K || n.mode === X ? 256 : 0), (0 === ut && 0 === ft || e === b) && Mt === S && (Mt = C), Mt)
				}, n.inflateEnd = function(t) {
					if(!t || !t.state) return T;
					var e = t.state;
					return e.window && (e.window = null), t.state = null, S
				}, n.inflateGetHeader = function(t, e) {
					var n;
					return t && t.state ? (n = t.state, 0 == (2 & n.wrap) ? T : (n.head = e, e.done = !1, S)) : T
				}, n.inflateSetDictionary = function(t, e) {
					var n, i, r = e.length;
					return t && t.state ? (n = t.state, 0 !== n.wrap && n.mode !== V ? T : n.mode === V && (i = 1, (i = d(i, e, r, 0)) !== n.check) ? A : h(t, e, r, r) ? (n.mode = lt, L) : (n.havedict = 1, S)) : T
				}, n.inflateInfo = "pako inflate (from Nodeca project)"
			}, {
				"../utils/common": 62,
				"./adler32": 64,
				"./crc32": 66,
				"./inffast": 69,
				"./inftrees": 71
			}],
			71: [function(t, e, n) {
				"use strict";
				var i = t("../utils/common"),
					r = 15,
					a = [3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31, 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0],
					o = [16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 72, 78],
					s = [1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577, 0, 0],
					l = [16, 16, 16, 16, 17, 17, 18, 18, 19, 19, 20, 20, 21, 21, 22, 22, 23, 23, 24, 24, 25, 25, 26, 26, 27, 27, 28, 28, 29, 29, 64, 64];
				e.exports = function(t, e, n, c, h, u, f, p) {
					var d, m, g, v, _, y, x, b, w, M = p.bits,
						S = 0,
						G = 0,
						E = 0,
						T = 0,
						A = 0,
						L = 0,
						C = 0,
						P = 0,
						I = 0,
						R = 0,
						O = null,
						N = 0,
						D = new i.Buf16(16),
						z = new i.Buf16(16),
						U = null,
						F = 0;
					for(S = 0; S <= r; S++) D[S] = 0;
					for(G = 0; G < c; G++) D[e[n + G]]++;
					for(A = M, T = r; T >= 1 && 0 === D[T]; T--);
					if(A > T && (A = T), 0 === T) return h[u++] = 20971520, h[u++] = 20971520, p.bits = 1, 0;
					for(E = 1; E < T && 0 === D[E]; E++);
					for(A < E && (A = E), P = 1, S = 1; S <= r; S++)
						if(P <<= 1, (P -= D[S]) < 0) return -1;
					if(P > 0 && (0 === t || 1 !== T)) return -1;
					for(z[1] = 0, S = 1; S < r; S++) z[S + 1] = z[S] + D[S];
					for(G = 0; G < c; G++) 0 !== e[n + G] && (f[z[e[n + G]]++] = G);
					if(0 === t ? (O = U = f, y = 19) : 1 === t ? (O = a, N -= 257, U = o, F -= 257, y = 256) : (O = s, U = l, y = -1), R = 0, G = 0, S = E, _ = u, L = A, C = 0, g = -1, I = 1 << A, v = I - 1, 1 === t && I > 852 || 2 === t && I > 592) return 1;
					for(;;) {
						x = S - C, f[G] < y ? (b = 0, w = f[G]) : f[G] > y ? (b = U[F + f[G]], w = O[N + f[G]]) : (b = 96, w = 0), d = 1 << S - C, E = m = 1 << L;
						do {
							m -= d, h[_ + (R >> C) + m] = x << 24 | b << 16 | w | 0
						} while (0 !== m);
						for(d = 1 << S - 1; R & d;) d >>= 1;
						if(0 !== d ? (R &= d - 1, R += d) : R = 0, G++, 0 == --D[S]) {
							if(S === T) break;
							S = e[n + f[G]]
						}
						if(S > A && (R & v) !== g) {
							for(0 === C && (C = A), _ += E, P = 1 << (L = S - C); L + C < T && !((P -= D[L + C]) <= 0);) L++, P <<= 1;
							if(I += 1 << L, 1 === t && I > 852 || 2 === t && I > 592) return 1;
							h[g = R & v] = A << 24 | L << 16 | _ - u | 0
						}
					}
					return 0 !== R && (h[_ + R] = S - C << 24 | 64 << 16 | 0), p.bits = A, 0
				}
			}, {
				"../utils/common": 62
			}],
			72: [function(t, e, n) {
				"use strict";
				e.exports = {
					2: "need dictionary",
					1: "stream end",
					0: "",
					"-1": "file error",
					"-2": "stream error",
					"-3": "data error",
					"-4": "insufficient memory",
					"-5": "buffer error",
					"-6": "incompatible version"
				}
			}, {}],
			73: [function(t, e, n) {
				"use strict";

				function i(t) {
					for(var e = t.length; --e >= 0;) t[e] = 0
				}

				function r(t, e, n, i, r) {
					this.static_tree = t, this.extra_bits = e, this.extra_base = n, this.elems = i, this.max_length = r, this.has_stree = t && t.length
				}

				function a(t, e) {
					this.dyn_tree = t, this.max_code = 0, this.stat_desc = e
				}

				function o(t) {
					return t < 256 ? et[t] : et[256 + (t >>> 7)]
				}

				function s(t, e) {
					t.pending_buf[t.pending++] = 255 & e, t.pending_buf[t.pending++] = e >>> 8 & 255
				}

				function l(t, e, n) {
					t.bi_valid > j - n ? (t.bi_buf |= e << t.bi_valid & 65535, s(t, t.bi_buf), t.bi_buf = e >> j - t.bi_valid, t.bi_valid += n - j) : (t.bi_buf |= e << t.bi_valid & 65535, t.bi_valid += n)
				}

				function c(t, e, n) {
					l(t, n[2 * e], n[2 * e + 1])
				}

				function h(t, e) {
					var n = 0;
					do {
						n |= 1 & t, t >>>= 1, n <<= 1
					} while (--e > 0);
					return n >>> 1
				}

				function u(t) {
					16 === t.bi_valid ? (s(t, t.bi_buf), t.bi_buf = 0, t.bi_valid = 0) : t.bi_valid >= 8 && (t.pending_buf[t.pending++] = 255 & t.bi_buf, t.bi_buf >>= 8, t.bi_valid -= 8)
				}

				function f(t, e) {
					var n, i, r, a, o, s, l = e.dyn_tree,
						c = e.max_code,
						h = e.stat_desc.static_tree,
						u = e.stat_desc.has_stree,
						f = e.stat_desc.extra_bits,
						p = e.stat_desc.extra_base,
						d = e.stat_desc.max_length,
						m = 0;
					for(a = 0; a <= V; a++) t.bl_count[a] = 0;
					for(l[2 * t.heap[t.heap_max] + 1] = 0, n = t.heap_max + 1; n < B; n++) i = t.heap[n], (a = l[2 * l[2 * i + 1] + 1] + 1) > d && (a = d, m++), l[2 * i + 1] = a, i > c || (t.bl_count[a]++, o = 0, i >= p && (o = f[i - p]), s = l[2 * i], t.opt_len += s * (a + o), u && (t.static_len += s * (h[2 * i + 1] + o)));
					if(0 !== m) {
						do {
							for(a = d - 1; 0 === t.bl_count[a];) a--;
							t.bl_count[a]--, t.bl_count[a + 1] += 2, t.bl_count[d]--, m -= 2
						} while (m > 0);
						for(a = d; 0 !== a; a--)
							for(i = t.bl_count[a]; 0 !== i;)(r = t.heap[--n]) > c || (l[2 * r + 1] !== a && (t.opt_len += (a - l[2 * r + 1]) * l[2 * r], l[2 * r + 1] = a), i--)
					}
				}

				function p(t, e, n) {
					var i, r, a = new Array(V + 1),
						o = 0;
					for(i = 1; i <= V; i++) a[i] = o = o + n[i - 1] << 1;
					for(r = 0; r <= e; r++) {
						var s = t[2 * r + 1];
						0 !== s && (t[2 * r] = h(a[s]++, s))
					}
				}

				function d() {
					var t, e, n, i, a, o = new Array(V + 1);
					for(n = 0, i = 0; i < D - 1; i++)
						for(it[i] = n, t = 0; t < 1 << Z[i]; t++) nt[n++] = i;
					for(nt[n - 1] = i, a = 0, i = 0; i < 16; i++)
						for(rt[i] = a, t = 0; t < 1 << J[i]; t++) et[a++] = i;
					for(a >>= 7; i < F; i++)
						for(rt[i] = a << 7, t = 0; t < 1 << J[i] - 7; t++) et[256 + a++] = i;
					for(e = 0; e <= V; e++) o[e] = 0;
					for(t = 0; t <= 143;) $[2 * t + 1] = 8, t++, o[8]++;
					for(; t <= 255;) $[2 * t + 1] = 9, t++, o[9]++;
					for(; t <= 279;) $[2 * t + 1] = 7, t++, o[7]++;
					for(; t <= 287;) $[2 * t + 1] = 8, t++, o[8]++;
					for(p($, U + 1, o), t = 0; t < F; t++) tt[2 * t + 1] = 5, tt[2 * t] = h(t, 5);
					at = new r($, Z, z + 1, U, V), ot = new r(tt, J, 0, F, V), st = new r(new Array(0), K, 0, k, H)
				}

				function m(t) {
					var e;
					for(e = 0; e < U; e++) t.dyn_ltree[2 * e] = 0;
					for(e = 0; e < F; e++) t.dyn_dtree[2 * e] = 0;
					for(e = 0; e < k; e++) t.bl_tree[2 * e] = 0;
					t.dyn_ltree[2 * W] = 1, t.opt_len = t.static_len = 0, t.last_lit = t.matches = 0
				}

				function g(t) {
					t.bi_valid > 8 ? s(t, t.bi_buf) : t.bi_valid > 0 && (t.pending_buf[t.pending++] = t.bi_buf), t.bi_buf = 0, t.bi_valid = 0
				}

				function v(t, e, n, i) {
					g(t), i && (s(t, n), s(t, ~n)), A.arraySet(t.pending_buf, t.window, e, n, t.pending), t.pending += n
				}

				function _(t, e, n, i) {
					var r = 2 * e,
						a = 2 * n;
					return t[r] < t[a] || t[r] === t[a] && i[e] <= i[n]
				}

				function y(t, e, n) {
					for(var i = t.heap[n], r = n << 1; r <= t.heap_len && (r < t.heap_len && _(e, t.heap[r + 1], t.heap[r], t.depth) && r++, !_(e, i, t.heap[r], t.depth));) t.heap[n] = t.heap[r], n = r, r <<= 1;
					t.heap[n] = i
				}

				function x(t, e, n) {
					var i, r, a, s, h = 0;
					if(0 !== t.last_lit)
						do {
							i = t.pending_buf[t.d_buf + 2 * h] << 8 | t.pending_buf[t.d_buf + 2 * h + 1], r = t.pending_buf[t.l_buf + h], h++, 0 === i ? c(t, r, e) : (a = nt[r], c(t, a + z + 1, e), 0 !== (s = Z[a]) && (r -= it[a], l(t, r, s)), i--, a = o(i), c(t, a, n), 0 !== (s = J[a]) && (i -= rt[a], l(t, i, s)))
						} while (h < t.last_lit);
					c(t, W, e)
				}

				function b(t, e) {
					var n, i, r, a = e.dyn_tree,
						o = e.stat_desc.static_tree,
						s = e.stat_desc.has_stree,
						l = e.stat_desc.elems,
						c = -1;
					for(t.heap_len = 0, t.heap_max = B, n = 0; n < l; n++) 0 !== a[2 * n] ? (t.heap[++t.heap_len] = c = n, t.depth[n] = 0) : a[2 * n + 1] = 0;
					for(; t.heap_len < 2;) r = t.heap[++t.heap_len] = c < 2 ? ++c : 0, a[2 * r] = 1, t.depth[r] = 0, t.opt_len--, s && (t.static_len -= o[2 * r + 1]);
					for(e.max_code = c, n = t.heap_len >> 1; n >= 1; n--) y(t, a, n);
					r = l;
					do {
						n = t.heap[1], t.heap[1] = t.heap[t.heap_len--], y(t, a, 1), i = t.heap[1], t.heap[--t.heap_max] = n, t.heap[--t.heap_max] = i, a[2 * r] = a[2 * n] + a[2 * i], t.depth[r] = (t.depth[n] >= t.depth[i] ? t.depth[n] : t.depth[i]) + 1, a[2 * n + 1] = a[2 * i + 1] = r, t.heap[1] = r++, y(t, a, 1)
					} while (t.heap_len >= 2);
					t.heap[--t.heap_max] = t.heap[1], f(t, e), p(a, c, t.bl_count)
				}

				function w(t, e, n) {
					var i, r, a = -1,
						o = e[1],
						s = 0,
						l = 7,
						c = 4;
					for(0 === o && (l = 138, c = 3), e[2 * (n + 1) + 1] = 65535, i = 0; i <= n; i++) r = o, o = e[2 * (i + 1) + 1], ++s < l && r === o || (s < c ? t.bl_tree[2 * r] += s : 0 !== r ? (r !== a && t.bl_tree[2 * r]++, t.bl_tree[2 * X]++) : s <= 10 ? t.bl_tree[2 * Y]++ : t.bl_tree[2 * q]++, s = 0, a = r, 0 === o ? (l = 138, c = 3) : r === o ? (l = 6, c = 3) : (l = 7, c = 4))
				}

				function M(t, e, n) {
					var i, r, a = -1,
						o = e[1],
						s = 0,
						h = 7,
						u = 4;
					for(0 === o && (h = 138, u = 3), i = 0; i <= n; i++)
						if(r = o, o = e[2 * (i + 1) + 1], !(++s < h && r === o)) {
							if(s < u)
								do {
									c(t, r, t.bl_tree)
								} while (0 != --s);
							else 0 !== r ? (r !== a && (c(t, r, t.bl_tree), s--), c(t, X, t.bl_tree), l(t, s - 3, 2)) : s <= 10 ? (c(t, Y, t.bl_tree), l(t, s - 3, 3)) : (c(t, q, t.bl_tree), l(t, s - 11, 7));
							s = 0, a = r, 0 === o ? (h = 138, u = 3) : r === o ? (h = 6, u = 3) : (h = 7, u = 4)
						}
				}

				function S(t) {
					var e;
					for(w(t, t.dyn_ltree, t.l_desc.max_code), w(t, t.dyn_dtree, t.d_desc.max_code), b(t, t.bl_desc), e = k - 1; e >= 3 && 0 === t.bl_tree[2 * Q[e] + 1]; e--);
					return t.opt_len += 3 * (e + 1) + 5 + 5 + 4, e
				}

				function G(t, e, n, i) {
					var r;
					for(l(t, e - 257, 5), l(t, n - 1, 5), l(t, i - 4, 4), r = 0; r < i; r++) l(t, t.bl_tree[2 * Q[r] + 1], 3);
					M(t, t.dyn_ltree, e - 1), M(t, t.dyn_dtree, n - 1)
				}

				function E(t) {
					var e, n = 4093624447;
					for(e = 0; e <= 31; e++, n >>>= 1)
						if(1 & n && 0 !== t.dyn_ltree[2 * e]) return C;
					if(0 !== t.dyn_ltree[18] || 0 !== t.dyn_ltree[20] || 0 !== t.dyn_ltree[26]) return P;
					for(e = 32; e < z; e++)
						if(0 !== t.dyn_ltree[2 * e]) return P;
					return C
				}

				function T(t, e, n, i) {
					l(t, (R << 1) + (i ? 1 : 0), 3), v(t, e, n, !0)
				}
				var A = t("../utils/common"),
					L = 4,
					C = 0,
					P = 1,
					I = 2,
					R = 0,
					O = 1,
					N = 2,
					D = 29,
					z = 256,
					U = z + 1 + D,
					F = 30,
					k = 19,
					B = 2 * U + 1,
					V = 15,
					j = 16,
					H = 7,
					W = 256,
					X = 16,
					Y = 17,
					q = 18,
					Z = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0],
					J = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13],
					K = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7],
					Q = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15],
					$ = new Array(2 * (U + 2));
				i($);
				var tt = new Array(2 * F);
				i(tt);
				var et = new Array(512);
				i(et);
				var nt = new Array(256);
				i(nt);
				var it = new Array(D);
				i(it);
				var rt = new Array(F);
				i(rt);
				var at, ot, st, lt = !1;
				n._tr_init = function(t) {
					lt || (d(), lt = !0), t.l_desc = new a(t.dyn_ltree, at), t.d_desc = new a(t.dyn_dtree, ot), t.bl_desc = new a(t.bl_tree, st), t.bi_buf = 0, t.bi_valid = 0, m(t)
				}, n._tr_stored_block = T, n._tr_flush_block = function(t, e, n, i) {
					var r, a, o = 0;
					t.level > 0 ? (t.strm.data_type === I && (t.strm.data_type = E(t)), b(t, t.l_desc), b(t, t.d_desc), o = S(t), r = t.opt_len + 3 + 7 >>> 3, (a = t.static_len + 3 + 7 >>> 3) <= r && (r = a)) : r = a = n + 5, n + 4 <= r && -1 !== e ? T(t, e, n, i) : t.strategy === L || a === r ? (l(t, (O << 1) + (i ? 1 : 0), 3), x(t, $, tt)) : (l(t, (N << 1) + (i ? 1 : 0), 3), G(t, t.l_desc.max_code + 1, t.d_desc.max_code + 1, o + 1), x(t, t.dyn_ltree, t.dyn_dtree)), m(t), i && g(t)
				}, n._tr_tally = function(t, e, n) {
					return t.pending_buf[t.d_buf + 2 * t.last_lit] = e >>> 8 & 255, t.pending_buf[t.d_buf + 2 * t.last_lit + 1] = 255 & e, t.pending_buf[t.l_buf + t.last_lit] = 255 & n, t.last_lit++, 0 === e ? t.dyn_ltree[2 * n]++ : (t.matches++, e--, t.dyn_ltree[2 * (nt[n] + z + 1)]++, t.dyn_dtree[2 * o(e)]++), t.last_lit === t.lit_bufsize - 1
				}, n._tr_align = function(t) {
					l(t, O << 1, 3), c(t, W, $), u(t)
				}
			}, {
				"../utils/common": 62
			}],
			74: [function(t, e, n) {
				"use strict";
				e.exports = function() {
					this.input = null, this.next_in = 0, this.avail_in = 0, this.total_in = 0, this.output = null, this.next_out = 0, this.avail_out = 0, this.total_out = 0, this.msg = "", this.state = null, this.data_type = 2, this.adler = 0
				}
			}, {}]
		}, {}, [10])(10)
	}),
	function(t) {
		"object" == typeof exports ? module.exports = t() : "function" == typeof define && define.amd ? define(t) : "undefined" != typeof window ? window.JSZipUtils = t() : "undefined" != typeof global ? global.JSZipUtils = t() : "undefined" != typeof self && (self.JSZipUtils = t())
	}(function() {
		return function t(e, n, i) {
			function r(o, s) {
				if(!n[o]) {
					if(!e[o]) {
						var l = "function" == typeof require && require;
						if(!s && l) return l(o, !0);
						if(a) return a(o, !0);
						throw new Error("Cannot find module '" + o + "'")
					}
					var c = n[o] = {
						exports: {}
					};
					e[o][0].call(c.exports, function(t) {
						var n = e[o][1][t];
						return r(n || t)
					}, c, c.exports, t, e, n, i)
				}
				return n[o].exports
			}
			for(var a = "function" == typeof require && require, o = 0; o < i.length; o++) r(i[o]);
			return r
		}({
			1: [function(t, e) {
				"use strict";

				function n() {
					try {
						return new window.XMLHttpRequest
					} catch(t) {}
				}

				function i() {
					try {
						return new window.ActiveXObject("Microsoft.XMLHTTP")
					} catch(t) {}
				}
				var r = {};
				r._getBinaryFromXHR = function(t) {
					return t.response || t.responseText
				};
				var a = window.ActiveXObject ? function() {
					return n() || i()
				} : n;
				r.getBinaryContent = function(t, e) {
					try {
						var n = a();
						n.open("GET", t, !0), "responseType" in n && (n.responseType = "arraybuffer"), n.overrideMimeType && n.overrideMimeType("text/plain; charset=x-user-defined"), n.onreadystatechange = function() {
							var i, a;
							if(4 === n.readyState)
								if(200 === n.status || 0 === n.status) {
									i = null, a = null;
									try {
										i = r._getBinaryFromXHR(n)
									} catch(t) {
										a = new Error(t)
									}
									e(a, i)
								} else e(new Error("Ajax error for " + t + " : " + this.status + " " + this.statusText), null)
						}, n.send()
					} catch(t) {
						e(new Error(t), null)
					}
				}, e.exports = r
			}, {}]
		}, {}, [1])(1)
	}),
	function(t, e) {
		"function" == typeof define && define.amd ? define(function() {
			return e(t)
		}) : e(t)
	}(this, function(t) {
		var e = function() {
			function e(t) {
				return null == t ? String(t) : Z[J.call(t)] || "object"
			}

			function n(t) {
				return "function" == e(t)
			}

			function i(t) {
				return null != t && t == t.window
			}

			function r(t) {
				return null != t && t.nodeType == t.DOCUMENT_NODE
			}

			function a(t) {
				return "object" == e(t)
			}

			function o(t) {
				return a(t) && !i(t) && Object.getPrototypeOf(t) == Object.prototype
			}

			function s(t) {
				var e = !!t && "length" in t && t.length,
					n = G.type(t);
				return "function" != n && !i(t) && ("array" == n || 0 === e || "number" == typeof e && e > 0 && e - 1 in t)
			}

			function l(t) {
				return P.call(t, function(t) {
					return null != t
				})
			}

			function c(t) {
				return t.length > 0 ? G.fn.concat.apply([], t) : t
			}

			function h(t) {
				return t.replace(/::/g, "/").replace(/([A-Z]+)([A-Z][a-z])/g, "$1_$2").replace(/([a-z\d])([A-Z])/g, "$1_$2").replace(/_/g, "-").toLowerCase()
			}

			function u(t) {
				return t in N ? N[t] : N[t] = new RegExp("(^|\\s)" + t + "(\\s|$)")
			}

			function f(t, e) {
				return "number" != typeof e || D[h(t)] ? e : e + "px"
			}

			function p(t) {
				var e, n;
				return O[t] || (e = R.createElement(t), R.body.appendChild(e), n = getComputedStyle(e, "").getPropertyValue("display"), e.parentNode.removeChild(e), "none" == n && (n = "block"), O[t] = n), O[t]
			}

			function d(t) {
				return "children" in t ? I.call(t.children) : G.map(t.childNodes, function(t) {
					return 1 == t.nodeType ? t : void 0
				})
			}

			function m(t, e) {
				var n, i = t ? t.length : 0;
				for(n = 0; i > n; n++) this[n] = t[n];
				this.length = i, this.selector = e || ""
			}

			function g(t, e, n) {
				for(S in e) n && (o(e[S]) || tt(e[S])) ? (o(e[S]) && !o(t[S]) && (t[S] = {}), tt(e[S]) && !tt(t[S]) && (t[S] = []), g(t[S], e[S], n)) : e[S] !== M && (t[S] = e[S])
			}

			function v(t, e) {
				return null == e ? G(t) : G(t).filter(e)
			}

			function _(t, e, i, r) {
				return n(e) ? e.call(t, i, r) : e
			}

			function y(t, e, n) {
				null == n ? t.removeAttribute(e) : t.setAttribute(e, n)
			}

			function x(t, e) {
				var n = t.className || "",
					i = n && n.baseVal !== M;
				return e === M ? i ? n.baseVal : n : void(i ? n.baseVal = e : t.className = e)
			}

			function b(t) {
				try {
					return t ? "true" == t || "false" != t && ("null" == t ? null : +t + "" == t ? +t : /^[\[\{]/.test(t) ? G.parseJSON(t) : t) : t
				} catch(e) {
					return t
				}
			}

			function w(t, e) {
				e(t);
				for(var n = 0, i = t.childNodes.length; i > n; n++) w(t.childNodes[n], e)
			}
			var M, S, G, E, T, A, L = [],
				C = L.concat,
				P = L.filter,
				I = L.slice,
				R = t.document,
				O = {},
				N = {},
				D = {
					"column-count": 1,
					columns: 1,
					"font-weight": 1,
					"line-height": 1,
					opacity: 1,
					"z-index": 1,
					zoom: 1
				},
				z = /^\s*<(\w+|!)[^>]*>/,
				U = /^<(\w+)\s*\/?>(?:<\/\1>|)$/,
				F = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,
				k = /^(?:body|html)$/i,
				B = /([A-Z])/g,
				V = ["val", "css", "html", "text", "data", "width", "height", "offset"],
				j = ["after", "prepend", "before", "append"],
				H = R.createElement("table"),
				W = R.createElement("tr"),
				X = {
					tr: R.createElement("tbody"),
					tbody: H,
					thead: H,
					tfoot: H,
					td: W,
					th: W,
					"*": R.createElement("div")
				},
				Y = /complete|loaded|interactive/,
				q = /^[\w-]*$/,
				Z = {},
				J = Z.toString,
				K = {},
				Q = R.createElement("div"),
				$ = {
					tabindex: "tabIndex",
					readonly: "readOnly",
					for: "htmlFor",
					class: "className",
					maxlength: "maxLength",
					cellspacing: "cellSpacing",
					cellpadding: "cellPadding",
					rowspan: "rowSpan",
					colspan: "colSpan",
					usemap: "useMap",
					frameborder: "frameBorder",
					contenteditable: "contentEditable"
				},
				tt = Array.isArray || function(t) {
					return t instanceof Array
				};
			return K.matches = function(t, e) {
				if(!e || !t || 1 !== t.nodeType) return !1;
				var n = t.matches || t.webkitMatchesSelector || t.mozMatchesSelector || t.oMatchesSelector || t.matchesSelector;
				if(n) return n.call(t, e);
				var i, r = t.parentNode,
					a = !r;
				return a && (r = Q).appendChild(t), i = ~K.qsa(r, e).indexOf(t), a && Q.removeChild(t), i
			}, T = function(t) {
				return t.replace(/-+(.)?/g, function(t, e) {
					return e ? e.toUpperCase() : ""
				})
			}, A = function(t) {
				return P.call(t, function(e, n) {
					return t.indexOf(e) == n
				})
			}, K.fragment = function(t, e, n) {
				var i, r, a;
				return U.test(t) && (i = G(R.createElement(RegExp.$1))), i || (t.replace && (t = t.replace(F, "<$1></$2>")), e === M && (e = z.test(t) && RegExp.$1), e in X || (e = "*"), a = X[e], a.innerHTML = "" + t, i = G.each(I.call(a.childNodes), function() {
					a.removeChild(this)
				})), o(n) && (r = G(i), G.each(n, function(t, e) {
					V.indexOf(t) > -1 ? r[t](e) : r.attr(t, e)
				})), i
			}, K.Z = function(t, e) {
				return new m(t, e)
			}, K.isZ = function(t) {
				return t instanceof K.Z
			}, K.init = function(t, e) {
				var i;
				if(!t) return K.Z();
				if("string" == typeof t)
					if("<" == (t = t.trim())[0] && z.test(t)) i = K.fragment(t, RegExp.$1, e), t = null;
					else {
						if(e !== M) return G(e).find(t);
						i = K.qsa(R, t)
					}
				else {
					if(n(t)) return G(R).ready(t);
					if(K.isZ(t)) return t;
					if(tt(t)) i = l(t);
					else if(a(t)) i = [t], t = null;
					else if(z.test(t)) i = K.fragment(t.trim(), RegExp.$1, e), t = null;
					else {
						if(e !== M) return G(e).find(t);
						i = K.qsa(R, t)
					}
				}
				return K.Z(i, t)
			}, G = function(t, e) {
				return K.init(t, e)
			}, G.extend = function(t) {
				var e, n = I.call(arguments, 1);
				return "boolean" == typeof t && (e = t, t = n.shift()), n.forEach(function(n) {
					g(t, n, e)
				}), t
			}, K.qsa = function(t, e) {
				var n, i = "#" == e[0],
					r = !i && "." == e[0],
					a = i || r ? e.slice(1) : e,
					o = q.test(a);
				return t.getElementById && o && i ? (n = t.getElementById(a)) ? [n] : [] : 1 !== t.nodeType && 9 !== t.nodeType && 11 !== t.nodeType ? [] : I.call(o && !i && t.getElementsByClassName ? r ? t.getElementsByClassName(a) : t.getElementsByTagName(e) : t.querySelectorAll(e))
			}, G.contains = R.documentElement.contains ? function(t, e) {
				return t !== e && t.contains(e)
			} : function(t, e) {
				for(; e && (e = e.parentNode);)
					if(e === t) return !0;
				return !1
			}, G.type = e, G.isFunction = n, G.isWindow = i, G.isArray = tt, G.isPlainObject = o, G.isEmptyObject = function(t) {
				var e;
				for(e in t) return !1;
				return !0
			}, G.isNumeric = function(t) {
				var e = Number(t),
					n = typeof t;
				return null != t && "boolean" != n && ("string" != n || t.length) && !isNaN(e) && isFinite(e) || !1
			}, G.inArray = function(t, e, n) {
				return L.indexOf.call(e, t, n)
			}, G.camelCase = T, G.trim = function(t) {
				return null == t ? "" : String.prototype.trim.call(t)
			}, G.uuid = 0, G.support = {}, G.expr = {}, G.noop = function() {}, G.map = function(t, e) {
				var n, i, r, a = [];
				if(s(t))
					for(i = 0; i < t.length; i++) null != (n = e(t[i], i)) && a.push(n);
				else
					for(r in t) null != (n = e(t[r], r)) && a.push(n);
				return c(a)
			}, G.each = function(t, e) {
				var n, i;
				if(s(t)) {
					for(n = 0; n < t.length; n++)
						if(!1 === e.call(t[n], n, t[n])) return t
				} else
					for(i in t)
						if(!1 === e.call(t[i], i, t[i])) return t;
				return t
			}, G.grep = function(t, e) {
				return P.call(t, e)
			}, t.JSON && (G.parseJSON = JSON.parse), G.each("Boolean Number String Function Array Date RegExp Object Error".split(" "), function(t, e) {
				Z["[object " + e + "]"] = e.toLowerCase()
			}), G.fn = {
				constructor: K.Z,
				length: 0,
				forEach: L.forEach,
				reduce: L.reduce,
				push: L.push,
				sort: L.sort,
				splice: L.splice,
				indexOf: L.indexOf,
				concat: function() {
					var t, e, n = [];
					for(t = 0; t < arguments.length; t++) e = arguments[t], n[t] = K.isZ(e) ? e.toArray() : e;
					return C.apply(K.isZ(this) ? this.toArray() : this, n)
				},
				map: function(t) {
					return G(G.map(this, function(e, n) {
						return t.call(e, n, e)
					}))
				},
				slice: function() {
					return G(I.apply(this, arguments))
				},
				ready: function(t) {
					return Y.test(R.readyState) && R.body ? t(G) : R.addEventListener("DOMContentLoaded", function() {
						t(G)
					}, !1), this
				},
				get: function(t) {
					return t === M ? I.call(this) : this[t >= 0 ? t : t + this.length]
				},
				toArray: function() {
					return this.get()
				},
				size: function() {
					return this.length
				},
				remove: function() {
					return this.each(function() {
						null != this.parentNode && this.parentNode.removeChild(this)
					})
				},
				each: function(t) {
					return L.every.call(this, function(e, n) {
						return !1 !== t.call(e, n, e)
					}), this
				},
				filter: function(t) {
					return n(t) ? this.not(this.not(t)) : G(P.call(this, function(e) {
						return K.matches(e, t)
					}))
				},
				add: function(t, e) {
					return G(A(this.concat(G(t, e))))
				},
				is: function(t) {
					return this.length > 0 && K.matches(this[0], t)
				},
				not: function(t) {
					var e = [];
					if(n(t) && t.call !== M) this.each(function(n) {
						t.call(this, n) || e.push(this)
					});
					else {
						var i = "string" == typeof t ? this.filter(t) : s(t) && n(t.item) ? I.call(t) : G(t);
						this.forEach(function(t) {
							i.indexOf(t) < 0 && e.push(t)
						})
					}
					return G(e)
				},
				has: function(t) {
					return this.filter(function() {
						return a(t) ? G.contains(this, t) : G(this).find(t).size()
					})
				},
				eq: function(t) {
					return -1 === t ? this.slice(t) : this.slice(t, +t + 1)
				},
				first: function() {
					var t = this[0];
					return t && !a(t) ? t : G(t)
				},
				last: function() {
					var t = this[this.length - 1];
					return t && !a(t) ? t : G(t)
				},
				find: function(t) {
					var e = this;
					return t ? "object" == typeof t ? G(t).filter(function() {
						var t = this;
						return L.some.call(e, function(e) {
							return G.contains(e, t)
						})
					}) : 1 == this.length ? G(K.qsa(this[0], t)) : this.map(function() {
						return K.qsa(this, t)
					}) : G()
				},
				closest: function(t, e) {
					var n = [],
						i = "object" == typeof t && G(t);
					return this.each(function(a, o) {
						for(; o && !(i ? i.indexOf(o) >= 0 : K.matches(o, t));) o = o !== e && !r(o) && o.parentNode;
						o && n.indexOf(o) < 0 && n.push(o)
					}), G(n)
				},
				parents: function(t) {
					for(var e = [], n = this; n.length > 0;) n = G.map(n, function(t) {
						return(t = t.parentNode) && !r(t) && e.indexOf(t) < 0 ? (e.push(t), t) : void 0
					});
					return v(e, t)
				},
				parent: function(t) {
					return v(A(this.pluck("parentNode")), t)
				},
				children: function(t) {
					return v(this.map(function() {
						return d(this)
					}), t)
				},
				contents: function() {
					return this.map(function() {
						return this.contentDocument || I.call(this.childNodes)
					})
				},
				siblings: function(t) {
					return v(this.map(function(t, e) {
						return P.call(d(e.parentNode), function(t) {
							return t !== e
						})
					}), t)
				},
				empty: function() {
					return this.each(function() {
						this.innerHTML = ""
					})
				},
				pluck: function(t) {
					return G.map(this, function(e) {
						return e[t]
					})
				},
				show: function() {
					return this.each(function() {
						"none" == this.style.display && (this.style.display = ""), "none" == getComputedStyle(this, "").getPropertyValue("display") && (this.style.display = p(this.nodeName))
					})
				},
				replaceWith: function(t) {
					return this.before(t).remove()
				},
				wrap: function(t) {
					var e = n(t);
					if(this[0] && !e) var i = G(t).get(0),
						r = i.parentNode || this.length > 1;
					return this.each(function(n) {
						G(this).wrapAll(e ? t.call(this, n) : r ? i.cloneNode(!0) : i)
					})
				},
				wrapAll: function(t) {
					if(this[0]) {
						G(this[0]).before(t = G(t));
						for(var e;
							(e = t.children()).length;) t = e.first();
						G(t).append(this)
					}
					return this
				},
				wrapInner: function(t) {
					var e = n(t);
					return this.each(function(n) {
						var i = G(this),
							r = i.contents(),
							a = e ? t.call(this, n) : t;
						r.length ? r.wrapAll(a) : i.append(a)
					})
				},
				unwrap: function() {
					return this.parent().each(function() {
						G(this).replaceWith(G(this).children())
					}), this
				},
				clone: function() {
					return this.map(function() {
						return this.cloneNode(!0)
					})
				},
				hide: function() {
					return this.css("display", "none")
				},
				toggle: function(t) {
					return this.each(function() {
						var e = G(this);
						(t === M ? "none" == e.css("display") : t) ? e.show(): e.hide()
					})
				},
				prev: function(t) {
					return G(this.pluck("previousElementSibling")).filter(t || "*")
				},
				next: function(t) {
					return G(this.pluck("nextElementSibling")).filter(t || "*")
				},
				html: function(t) {
					return 0 in arguments ? this.each(function(e) {
						var n = this.innerHTML;
						G(this).empty().append(_(this, t, e, n))
					}) : 0 in this ? this[0].innerHTML : null
				},
				text: function(t) {
					return 0 in arguments ? this.each(function(e) {
						var n = _(this, t, e, this.textContent);
						this.textContent = null == n ? "" : "" + n
					}) : 0 in this ? this.pluck("textContent").join("") : null
				},
				attr: function(t, e) {
					var n;
					return "string" != typeof t || 1 in arguments ? this.each(function(n) {
						if(1 === this.nodeType)
							if(a(t))
								for(S in t) y(this, S, t[S]);
							else y(this, t, _(this, e, n, this.getAttribute(t)))
					}) : 0 in this && 1 == this[0].nodeType && null != (n = this[0].getAttribute(t)) ? n : M
				},
				removeAttr: function(t) {
					return this.each(function() {
						1 === this.nodeType && t.split(" ").forEach(function(t) {
							y(this, t)
						}, this)
					})
				},
				prop: function(t, e) {
					return t = $[t] || t, 1 in arguments ? this.each(function(n) {
						this[t] = _(this, e, n, this[t])
					}) : this[0] && this[0][t]
				},
				removeProp: function(t) {
					return t = $[t] || t, this.each(function() {
						delete this[t]
					})
				},
				data: function(t, e) {
					var n = "data-" + t.replace(B, "-$1").toLowerCase(),
						i = 1 in arguments ? this.attr(n, e) : this.attr(n);
					return null !== i ? b(i) : M
				},
				val: function(t) {
					return 0 in arguments ? (null == t && (t = ""), this.each(function(e) {
						this.value = _(this, t, e, this.value)
					})) : this[0] && (this[0].multiple ? G(this[0]).find("option").filter(function() {
						return this.selected
					}).pluck("value") : this[0].value)
				},
				offset: function(e) {
					if(e) return this.each(function(t) {
						var n = G(this),
							i = _(this, e, t, n.offset()),
							r = n.offsetParent().offset(),
							a = {
								top: i.top - r.top,
								left: i.left - r.left
							};
						"static" == n.css("position") && (a.position = "relative"), n.css(a)
					});
					if(!this.length) return null;
					if(R.documentElement !== this[0] && !G.contains(R.documentElement, this[0])) return {
						top: 0,
						left: 0
					};
					var n = this[0].getBoundingClientRect();
					return {
						left: n.left + t.pageXOffset,
						top: n.top + t.pageYOffset,
						width: Math.round(n.width),
						height: Math.round(n.height)
					}
				},
				css: function(t, n) {
					if(arguments.length < 2) {
						var i = this[0];
						if("string" == typeof t) {
							if(!i) return;
							return i.style[T(t)] || getComputedStyle(i, "").getPropertyValue(t)
						}
						if(tt(t)) {
							if(!i) return;
							var r = {},
								a = getComputedStyle(i, "");
							return G.each(t, function(t, e) {
								r[e] = i.style[T(e)] || a.getPropertyValue(e)
							}), r
						}
					}
					var o = "";
					if("string" == e(t)) n || 0 === n ? o = h(t) + ":" + f(t, n) : this.each(function() {
						this.style.removeProperty(h(t))
					});
					else
						for(S in t) t[S] || 0 === t[S] ? o += h(S) + ":" + f(S, t[S]) + ";" : this.each(function() {
							this.style.removeProperty(h(S))
						});
					return this.each(function() {
						this.style.cssText += ";" + o
					})
				},
				index: function(t) {
					return t ? this.indexOf(G(t)[0]) : this.parent().children().indexOf(this[0])
				},
				hasClass: function(t) {
					return !!t && L.some.call(this, function(t) {
						return this.test(x(t))
					}, u(t))
				},
				addClass: function(t) {
					return t ? this.each(function(e) {
						if("className" in this) {
							E = [];
							var n = x(this);
							_(this, t, e, n).split(/\s+/g).forEach(function(t) {
								G(this).hasClass(t) || E.push(t)
							}, this), E.length && x(this, n + (n ? " " : "") + E.join(" "))
						}
					}) : this
				},
				removeClass: function(t) {
					return this.each(function(e) {
						if("className" in this) {
							if(t === M) return x(this, "");
							E = x(this), _(this, t, e, E).split(/\s+/g).forEach(function(t) {
								E = E.replace(u(t), " ")
							}), x(this, E.trim())
						}
					})
				},
				toggleClass: function(t, e) {
					return t ? this.each(function(n) {
						var i = G(this);
						_(this, t, n, x(this)).split(/\s+/g).forEach(function(t) {
							(e === M ? !i.hasClass(t) : e) ? i.addClass(t): i.removeClass(t)
						})
					}) : this
				},
				scrollTop: function(t) {
					if(this.length) {
						var e = "scrollTop" in this[0];
						return t === M ? e ? this[0].scrollTop : this[0].pageYOffset : this.each(e ? function() {
							this.scrollTop = t
						} : function() {
							this.scrollTo(this.scrollX, t)
						})
					}
				},
				scrollLeft: function(t) {
					if(this.length) {
						var e = "scrollLeft" in this[0];
						return t === M ? e ? this[0].scrollLeft : this[0].pageXOffset : this.each(e ? function() {
							this.scrollLeft = t
						} : function() {
							this.scrollTo(t, this.scrollY)
						})
					}
				},
				position: function() {
					if(this.length) {
						var t = this[0],
							e = this.offsetParent(),
							n = this.offset(),
							i = k.test(e[0].nodeName) ? {
								top: 0,
								left: 0
							} : e.offset();
						return n.top -= parseFloat(G(t).css("margin-top")) || 0, n.left -= parseFloat(G(t).css("margin-left")) || 0, i.top += parseFloat(G(e[0]).css("border-top-width")) || 0, i.left += parseFloat(G(e[0]).css("border-left-width")) || 0, {
							top: n.top - i.top,
							left: n.left - i.left
						}
					}
				},
				offsetParent: function() {
					return this.map(function() {
						for(var t = this.offsetParent || R.body; t && !k.test(t.nodeName) && "static" == G(t).css("position");) t = t.offsetParent;
						return t
					})
				}
			}, G.fn.detach = G.fn.remove, ["width", "height"].forEach(function(t) {
				var e = t.replace(/./, function(t) {
					return t[0].toUpperCase()
				});
				G.fn[t] = function(n) {
					var a, o = this[0];
					return n === M ? i(o) ? o["inner" + e] : r(o) ? o.documentElement["scroll" + e] : (a = this.offset()) && a[t] : this.each(function(e) {
						(o = G(this)).css(t, _(this, n, e, o[t]()))
					})
				}
			}), j.forEach(function(n, i) {
				var r = i % 2;
				G.fn[n] = function() {
					var n, a, o = G.map(arguments, function(t) {
							var i = [];
							return n = e(t), "array" == n ? (t.forEach(function(t) {
								return t.nodeType !== M ? i.push(t) : G.zepto.isZ(t) ? i = i.concat(t.get()) : void(i = i.concat(K.fragment(t)))
							}), i) : "object" == n || null == t ? t : K.fragment(t)
						}),
						s = this.length > 1;
					return o.length < 1 ? this : this.each(function(e, n) {
						a = r ? n : n.parentNode, n = 0 == i ? n.nextSibling : 1 == i ? n.firstChild : 2 == i ? n : null;
						var l = G.contains(R.documentElement, a);
						o.forEach(function(e) {
							if(s) e = e.cloneNode(!0);
							else if(!a) return G(e).remove();
							a.insertBefore(e, n), l && w(e, function(e) {
								if(!(null == e.nodeName || "SCRIPT" !== e.nodeName.toUpperCase() || e.type && "text/javascript" !== e.type || e.src)) {
									var n = e.ownerDocument ? e.ownerDocument.defaultView : t;
									n.eval.call(n, e.innerHTML)
								}
							})
						})
					})
				}, G.fn[r ? n + "To" : "insert" + (i ? "Before" : "After")] = function(t) {
					return G(t)[n](this), this
				}
			}), K.Z.prototype = m.prototype = G.fn, K.uniq = A, K.deserializeValue = b, G.zepto = K, G
		}();
		return t.Zepto = e, void 0 === t.$ && (t.$ = e),
			function(e) {
				function n(t) {
					return t._zid || (t._zid = p++)
				}

				function i(t, e, i, o) {
					if((e = r(e)).ns) var s = a(e.ns);
					return(v[n(t)] || []).filter(function(t) {
						return t && (!e.e || t.e == e.e) && (!e.ns || s.test(t.ns)) && (!i || n(t.fn) === n(i)) && (!o || t.sel == o)
					})
				}

				function r(t) {
					var e = ("" + t).split(".");
					return {
						e: e[0],
						ns: e.slice(1).sort().join(" ")
					}
				}

				function a(t) {
					return new RegExp("(?:^| )" + t.replace(" ", " .* ?") + "(?: |$)")
				}

				function o(t, e) {
					return t.del && !y && t.e in x || !!e
				}

				function s(t) {
					return b[t] || y && x[t] || t
				}

				function l(t, i, a, l, c, u, p) {
					var d = n(t),
						m = v[d] || (v[d] = []);
					i.split(/\s/).forEach(function(n) {
						if("ready" == n) return e(document).ready(a);
						var i = r(n);
						i.fn = a, i.sel = c, i.e in b && (a = function(t) {
							var n = t.relatedTarget;
							return !n || n !== this && !e.contains(this, n) ? i.fn.apply(this, arguments) : void 0
						}), i.del = u;
						var d = u || a;
						i.proxy = function(e) {
							if(!(e = h(e)).isImmediatePropagationStopped()) {
								e.data = l;
								var n = d.apply(t, e._args == f ? [e] : [e].concat(e._args));
								return !1 === n && (e.preventDefault(), e.stopPropagation()), n
							}
						}, i.i = m.length, m.push(i), "addEventListener" in t && t.addEventListener(s(i.e), i.proxy, o(i, p))
					})
				}

				function c(t, e, r, a, l) {
					var c = n(t);
					(e || "").split(/\s/).forEach(function(e) {
						i(t, e, r, a).forEach(function(e) {
							delete v[c][e.i], "removeEventListener" in t && t.removeEventListener(s(e.e), e.proxy, o(e, l))
						})
					})
				}

				function h(t, n) {
					return(n || !t.isDefaultPrevented) && (n || (n = t), e.each(G, function(e, i) {
						var r = n[e];
						t[e] = function() {
							return this[i] = w, r && r.apply(n, arguments)
						}, t[i] = M
					}), t.timeStamp || (t.timeStamp = Date.now()), (n.defaultPrevented !== f ? n.defaultPrevented : "returnValue" in n ? !1 === n.returnValue : n.getPreventDefault && n.getPreventDefault()) && (t.isDefaultPrevented = w)), t
				}

				function u(t) {
					var e, n = {
						originalEvent: t
					};
					for(e in t) S.test(e) || t[e] === f || (n[e] = t[e]);
					return h(n, t)
				}
				var f, p = 1,
					d = Array.prototype.slice,
					m = e.isFunction,
					g = function(t) {
						return "string" == typeof t
					},
					v = {},
					_ = {},
					y = "onfocusin" in t,
					x = {
						focus: "focusin",
						blur: "focusout"
					},
					b = {
						mouseenter: "mouseover",
						mouseleave: "mouseout"
					};
				_.click = _.mousedown = _.mouseup = _.mousemove = "MouseEvents", e.event = {
					add: l,
					remove: c
				}, e.proxy = function(t, i) {
					var r = 2 in arguments && d.call(arguments, 2);
					if(m(t)) {
						var a = function() {
							return t.apply(i, r ? r.concat(d.call(arguments)) : arguments)
						};
						return a._zid = n(t), a
					}
					if(g(i)) return r ? (r.unshift(t[i], t), e.proxy.apply(null, r)) : e.proxy(t[i], t);
					throw new TypeError("expected function")
				}, e.fn.bind = function(t, e, n) {
					return this.on(t, e, n)
				}, e.fn.unbind = function(t, e) {
					return this.off(t, e)
				}, e.fn.one = function(t, e, n, i) {
					return this.on(t, e, n, i, 1)
				};
				var w = function() {
						return !0
					},
					M = function() {
						return !1
					},
					S = /^([A-Z]|returnValue$|layer[XY]$|webkitMovement[XY]$)/,
					G = {
						preventDefault: "isDefaultPrevented",
						stopImmediatePropagation: "isImmediatePropagationStopped",
						stopPropagation: "isPropagationStopped"
					};
				e.fn.delegate = function(t, e, n) {
					return this.on(e, t, n)
				}, e.fn.undelegate = function(t, e, n) {
					return this.off(e, t, n)
				}, e.fn.live = function(t, n) {
					return e(document.body).delegate(this.selector, t, n), this
				}, e.fn.die = function(t, n) {
					return e(document.body).undelegate(this.selector, t, n), this
				}, e.fn.on = function(t, n, i, r, a) {
					var o, s, h = this;
					return t && !g(t) ? (e.each(t, function(t, e) {
						h.on(t, n, i, e, a)
					}), h) : (g(n) || m(r) || !1 === r || (r = i, i = n, n = f), (r === f || !1 === i) && (r = i, i = f), !1 === r && (r = M), h.each(function(h, f) {
						a && (o = function(t) {
							return c(f, t.type, r), r.apply(this, arguments)
						}), n && (s = function(t) {
							var i, a = e(t.target).closest(n, f).get(0);
							return a && a !== f ? (i = e.extend(u(t), {
								currentTarget: a,
								liveFired: f
							}), (o || r).apply(a, [i].concat(d.call(arguments, 1)))) : void 0
						}), l(f, t, r, i, n, s || o)
					}))
				}, e.fn.off = function(t, n, i) {
					var r = this;
					return t && !g(t) ? (e.each(t, function(t, e) {
						r.off(t, n, e)
					}), r) : (g(n) || m(i) || !1 === i || (i = n, n = f), !1 === i && (i = M), r.each(function() {
						c(this, t, i, n)
					}))
				}, e.fn.trigger = function(t, n) {
					return t = g(t) || e.isPlainObject(t) ? e.Event(t) : h(t), t._args = n, this.each(function() {
						t.type in x && "function" == typeof this[t.type] ? this[t.type]() : "dispatchEvent" in this ? this.dispatchEvent(t) : e(this).triggerHandler(t, n)
					})
				}, e.fn.triggerHandler = function(t, n) {
					var r, a;
					return this.each(function(o, s) {
						(r = u(g(t) ? e.Event(t) : t))._args = n, r.target = s, e.each(i(s, t.type || t), function(t, e) {
							return a = e.proxy(r), !r.isImmediatePropagationStopped() && void 0
						})
					}), a
				}, "focusin focusout focus blur load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select keydown keypress keyup error".split(" ").forEach(function(t) {
					e.fn[t] = function(e) {
						return 0 in arguments ? this.bind(t, e) : this.trigger(t)
					}
				}), e.Event = function(t, e) {
					g(t) || (e = t, t = e.type);
					var n = document.createEvent(_[t] || "Events"),
						i = !0;
					if(e)
						for(var r in e) "bubbles" == r ? i = !!e[r] : n[r] = e[r];
					return n.initEvent(t, i, !0), h(n)
				}
			}(e),
			function(e) {
				function n(t, n, i) {
					var r = e.Event(n);
					return e(t).trigger(r, i), !r.isDefaultPrevented()
				}

				function i(t, e, i, r) {
					return t.global ? n(e || x, i, r) : void 0
				}

				function r(t) {
					t.global && 0 == e.active++ && i(t, null, "ajaxStart")
				}

				function a(t) {
					t.global && !--e.active && i(t, null, "ajaxStop")
				}

				function o(t, e) {
					var n = e.context;
					return !1 !== e.beforeSend.call(n, t, e) && !1 !== i(e, n, "ajaxBeforeSend", [t, e]) && void i(e, n, "ajaxSend", [t, e])
				}

				function s(t, e, n, r) {
					var a = n.context,
						o = "success";
					n.success.call(a, t, o, e), r && r.resolveWith(a, [t, o, e]), i(n, a, "ajaxSuccess", [e, n, t]), c(o, e, n)
				}

				function l(t, e, n, r, a) {
					var o = r.context;
					r.error.call(o, n, e, t), a && a.rejectWith(o, [n, e, t]), i(r, o, "ajaxError", [n, r, t || e]), c(e, n, r)
				}

				function c(t, e, n) {
					var r = n.context;
					n.complete.call(r, e, t), i(n, r, "ajaxComplete", [e, n]), a(n)
				}

				function h(t, e, n) {
					if(n.dataFilter == u) return t;
					var i = n.context;
					return n.dataFilter.call(i, t, e)
				}

				function u() {}

				function f(t) {
					return t && (t = t.split(";", 2)[0]), t && (t == G ? "html" : t == S ? "json" : w.test(t) ? "script" : M.test(t) && "xml") || "text"
				}

				function p(t, e) {
					return "" == e ? t : (t + "&" + e).replace(/[&?]{1,2}/, "?")
				}

				function d(t) {
					t.processData && t.data && "string" != e.type(t.data) && (t.data = e.param(t.data, t.traditional)), !t.data || t.type && "GET" != t.type.toUpperCase() && "jsonp" != t.dataType || (t.url = p(t.url, t.data), t.data = void 0)
				}

				function m(t, n, i, r) {
					return e.isFunction(n) && (r = i, i = n, n = void 0), e.isFunction(i) || (r = i, i = void 0), {
						url: t,
						data: n,
						success: i,
						dataType: r
					}
				}

				function g(t, n, i, r) {
					var a, o = e.isArray(n),
						s = e.isPlainObject(n);
					e.each(n, function(n, l) {
						a = e.type(l), r && (n = i ? r : r + "[" + (s || "object" == a || "array" == a ? n : "") + "]"), !r && o ? t.add(l.name, l.value) : "array" == a || !i && "object" == a ? g(t, l, i, n) : t.add(n, l)
					})
				}
				var v, _, y = +new Date,
					x = t.document,
					b = /<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,
					w = /^(?:text|application)\/javascript/i,
					M = /^(?:text|application)\/xml/i,
					S = "application/json",
					G = "text/html",
					E = /^\s*$/,
					T = x.createElement("a");
				T.href = t.location.href, e.active = 0, e.ajaxJSONP = function(n, i) {
					if(!("type" in n)) return e.ajax(n);
					var r, a, c = n.jsonpCallback,
						h = (e.isFunction(c) ? c() : c) || "Zepto" + y++,
						u = x.createElement("script"),
						f = t[h],
						p = function(t) {
							e(u).triggerHandler("error", t || "abort")
						},
						d = {
							abort: p
						};
					return i && i.promise(d), e(u).on("load error", function(o, c) {
						clearTimeout(a), e(u).off().remove(), "error" != o.type && r ? s(r[0], d, n, i) : l(null, c || "error", d, n, i), t[h] = f, r && e.isFunction(f) && f(r[0]), f = r = void 0
					}), !1 === o(d, n) ? (p("abort"), d) : (t[h] = function() {
						r = arguments
					}, u.src = n.url.replace(/\?(.+)=\?/, "?$1=" + h), x.head.appendChild(u), n.timeout > 0 && (a = setTimeout(function() {
						p("timeout")
					}, n.timeout)), d)
				}, e.ajaxSettings = {
					type: "GET",
					beforeSend: u,
					success: u,
					error: u,
					complete: u,
					context: null,
					global: !0,
					xhr: function() {
						return new t.XMLHttpRequest
					},
					accepts: {
						script: "text/javascript, application/javascript, application/x-javascript",
						json: S,
						xml: "application/xml, text/xml",
						html: G,
						text: "text/plain"
					},
					crossDomain: !1,
					timeout: 0,
					processData: !0,
					cache: !0,
					dataFilter: u
				}, e.ajax = function(n) {
					var i, a, c = e.extend({}, n || {}),
						m = e.Deferred && e.Deferred();
					for(v in e.ajaxSettings) void 0 === c[v] && (c[v] = e.ajaxSettings[v]);
					r(c), c.crossDomain || (i = x.createElement("a"), i.href = c.url, i.href = i.href, c.crossDomain = T.protocol + "//" + T.host != i.protocol + "//" + i.host), c.url || (c.url = t.location.toString()), (a = c.url.indexOf("#")) > -1 && (c.url = c.url.slice(0, a)), d(c);
					var g = c.dataType,
						y = /\?.+=\?/.test(c.url);
					if(y && (g = "jsonp"), !1 !== c.cache && (n && !0 === n.cache || "script" != g && "jsonp" != g) || (c.url = p(c.url, "_=" + Date.now())), "jsonp" == g) return y || (c.url = p(c.url, c.jsonp ? c.jsonp + "=?" : !1 === c.jsonp ? "" : "callback=?")), e.ajaxJSONP(c, m);
					var b, w = c.accepts[g],
						M = {},
						S = function(t, e) {
							M[t.toLowerCase()] = [t, e]
						},
						G = /^([\w-]+:)\/\//.test(c.url) ? RegExp.$1 : t.location.protocol,
						A = c.xhr(),
						L = A.setRequestHeader;
					if(m && m.promise(A), c.crossDomain || S("X-Requested-With", "XMLHttpRequest"), S("Accept", w || "*/*"), (w = c.mimeType || w) && (w.indexOf(",") > -1 && (w = w.split(",", 2)[0]), A.overrideMimeType && A.overrideMimeType(w)), (c.contentType || !1 !== c.contentType && c.data && "GET" != c.type.toUpperCase()) && S("Content-Type", c.contentType || "application/x-www-form-urlencoded"), c.headers)
						for(_ in c.headers) S(_, c.headers[_]);
					if(A.setRequestHeader = S, A.onreadystatechange = function() {
							if(4 == A.readyState) {
								A.onreadystatechange = u, clearTimeout(b);
								var t, n = !1;
								if(A.status >= 200 && A.status < 300 || 304 == A.status || 0 == A.status && "file:" == G) {
									if(g = g || f(c.mimeType || A.getResponseHeader("content-type")), "arraybuffer" == A.responseType || "blob" == A.responseType) t = A.response;
									else {
										t = A.responseText;
										try {
											t = h(t, g, c), "script" == g ? (0, eval)(t) : "xml" == g ? t = A.responseXML : "json" == g && (t = E.test(t) ? null : e.parseJSON(t))
										} catch(t) {
											n = t
										}
										if(n) return l(n, "parsererror", A, c, m)
									}
									s(t, A, c, m)
								} else l(A.statusText || null, A.status ? "error" : "abort", A, c, m)
							}
						}, !1 === o(A, c)) return A.abort(), l(null, "abort", A, c, m), A;
					var C = !("async" in c) || c.async;
					if(A.open(c.type, c.url, C, c.username, c.password), c.xhrFields)
						for(_ in c.xhrFields) A[_] = c.xhrFields[_];
					for(_ in M) L.apply(A, M[_]);
					return c.timeout > 0 && (b = setTimeout(function() {
						A.onreadystatechange = u, A.abort(), l(null, "timeout", A, c, m)
					}, c.timeout)), A.send(c.data ? c.data : null), A
				}, e.get = function() {
					return e.ajax(m.apply(null, arguments))
				}, e.post = function() {
					var t = m.apply(null, arguments);
					return t.type = "POST", e.ajax(t)
				}, e.getJSON = function() {
					var t = m.apply(null, arguments);
					return t.dataType = "json", e.ajax(t)
				}, e.fn.load = function(t, n, i) {
					if(!this.length) return this;
					var r, a = this,
						o = t.split(/\s/),
						s = m(t, n, i),
						l = s.success;
					return o.length > 1 && (s.url = o[0], r = o[1]), s.success = function(t) {
						a.html(r ? e("<div>").html(t.replace(b, "")).find(r) : t), l && l.apply(a, arguments)
					}, e.ajax(s), this
				};
				var A = encodeURIComponent;
				e.param = function(t, n) {
					var i = [];
					return i.add = function(t, n) {
						e.isFunction(n) && (n = n()), null == n && (n = ""), this.push(A(t) + "=" + A(n))
					}, g(i, t, n), i.join("&").replace(/%20/g, "+")
				}
			}(e),
			function(t) {
				t.fn.serializeArray = function() {
					var e, n, i = [],
						r = function(t) {
							return t.forEach ? t.forEach(r) : void i.push({
								name: e,
								value: t
							})
						};
					return this[0] && t.each(this[0].elements, function(i, a) {
						n = a.type, (e = a.name) && "fieldset" != a.nodeName.toLowerCase() && !a.disabled && "submit" != n && "reset" != n && "button" != n && "file" != n && ("radio" != n && "checkbox" != n || a.checked) && r(t(a).val())
					}), i
				}, t.fn.serialize = function() {
					var t = [];
					return this.serializeArray().forEach(function(e) {
						t.push(encodeURIComponent(e.name) + "=" + encodeURIComponent(e.value))
					}), t.join("&")
				}, t.fn.submit = function(e) {
					if(0 in arguments) this.bind("submit", e);
					else if(this.length) {
						var n = t.Event("submit");
						this.eq(0).trigger(n), n.isDefaultPrevented() || this.get(0).submit()
					}
					return this
				}
			}(e),
			function() {
				try {
					getComputedStyle(void 0)
				} catch(n) {
					var e = getComputedStyle;
					t.getComputedStyle = function(t, n) {
						try {
							return e(t, n)
						} catch(t) {
							return null
						}
					}
				}
			}(), e
	});